diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/list/list.h | 8 | ||||
-rw-r--r-- | src/type.h | 16 |
2 files changed, 15 insertions, 9 deletions
diff --git a/src/list/list.h b/src/list/list.h index cf4f415..c23362a 100644 --- a/src/list/list.h +++ b/src/list/list.h @@ -18,11 +18,11 @@ using ListOfType = List< std::integral_constant<Type, Values>... >; -template <typename Cons> -using Head = Car<Cons>; +template <typename Pair> +using Head = Car<Pair>; -template <typename Cons> -using Tail = Cdr<Cons>; +template <typename Pair> +using Tail = Cdr<Pair>; } @@ -24,10 +24,16 @@ template < typename X, typename Y > -using IsEqualType = Eval<std::is_same< +using IsEqual = Eval<std::is_same<X, Y>>; + +template < + typename X, + typename Y +> +using IsEqualType = IsEqual< typename X::value_type, typename Y::value_type ->>; +>; template < typename X, @@ -36,13 +42,13 @@ template < using IsEqualValue = Boolean<X::value == Y::value>; template <typename X> -using IsTrue = IsEqualValue<X, Boolean<true>>; +using IsBoolean = IsEqual<typename X::value_type, bool>; template <typename X> -using IsBoolean = Eval<std::is_same<typename X::value_type, bool>>; +using IsTrue = IsEqualValue<X, Boolean<true>>; template <typename X> -using IsSize = Eval<std::is_same<typename X::value_type, std::size_t>>; +using IsSize = IsEqual<typename X::value_type, std::size_t>; } |