cxxomfort
rel.20211024
Simple backports for C++ - https://ryan.gulix.cl/fossil.cgi/cxxomfort/
|
Implementation details for "static_assert" backport. More...
Macros | |
#define | static_assert(test, msg) enum { CXXO_JOIN(sassert_e_,__COUNTER__) = 1/(test) } |
Provides an assertion at compile-time. More... | |
Implementation details for "static_assert" backport.
#define static_assert | ( | test, | |
msg | |||
) | enum { CXXO_JOIN(sassert_e_,__COUNTER__) = 1/(test) } |
Provides an assertion at compile-time.
test | The boolean test to run, must be computable at compile-time |
msg | The string literal to provide as a compiler error message if the assertion does not hold |
Referenced by cxxomfort::fix::clamp(), cxxomfort::cxxostd::get(), cxxomfort::max(), and unique_ptr< T, D >::unique_ptr().