VCCC  2024.05
VisualCamp Common C++ library
constexpr.hpp
Go to the documentation of this file.
1 //
2 // Created by yonggyulee on 2024/01/03.
3 //
4 
5 #ifndef VCCC_CORE_CONSTEXPR_HPP
6 #define VCCC_CORE_CONSTEXPR_HPP
7 
8 // TODO: Use CheckCXXSybolExists
9 #define VCCC_CONSTEXPR constexpr
10 
11 #if __cplusplus >= 201402L
12 #define VCCC_CONSTEXPR_AFTER_CXX14 constexpr
13 #else
14 #define VCCC_CONSTEXPR_AFTER_CXX14
15 #endif
16 
17 #if __cplusplus >= 201703L
18 #define VCCC_CONSTEXPR_AFTER_CXX17 constexpr
19 #else
20 #define VCCC_CONSTEXPR_AFTER_CXX17
21 #endif
22 
23 #if __cplusplus >= 202002L
24 #define VCCC_CONSTEXPR_AFTER_CXX20 constexpr
25 #else
26 #define VCCC_CONSTEXPR_AFTER_CXX20
27 #endif
28 
29 #if __cplusplus >= 202302L
30 #define VCCC_CONSTEXPR_AFTER_CXX23 constexpr
31 #else
32 #define VCCC_CONSTEXPR_AFTER_CXX23
33 #endif
34 
35 #endif // VCCC_CORE_CONSTEXPR_HPP