blob: 304bff4288a0a3d5b0d15a84b7ddabbb8513c6e9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#ifndef TYPEASVALUE_SRC_TYPE_H_
#define TYPEASVALUE_SRC_TYPE_H_
#include <type_traits>
namespace tav {
template <int Value>
using Int = typename std::integral_constant<int, Value>::type;
template <bool Value>
using Boolean = typename std::integral_constant<bool, Value>::type;
template <
typename X,
typename Y
>
using equal_type = typename std::integral_constant<
bool,
std::is_same<typename X::value_type, typename Y::value_type>::value
>::type;
template <
typename X,
typename Y
>
using equal_value = typename std::integral_constant<
bool,
X::value == Y::value
>::type;
}
#endif // TYPEASVALUE_SRC_TYPE_H_
|