Skip to content

Commit

Permalink
Basic CTL shared_ptr implementation (#1267)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrdomino authored Aug 31, 2024
1 parent a6fe62c commit e1528a7
Show file tree
Hide file tree
Showing 4 changed files with 708 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ctl/conditional.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ struct conditional<false, T, F>
typedef F type;
};

template<bool B, typename T, typename F>
using conditional_t = typename conditional<B, T, F>::type;

} // namespace ctl

#endif // CTL_CONDITIONAL_H_
3 changes: 3 additions & 0 deletions ctl/is_void.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ template<typename _Tp>
struct is_void : public is_void_<typename ctl::remove_cv<_Tp>::type>::type
{};

template<typename T>
inline constexpr bool is_void_v = is_void<T>::value;

} // namespace ctl

#endif // CTL_IS_VOID_H_
Loading

0 comments on commit e1528a7

Please sign in to comment.