Performs compile-time assertion checking.
Syntax
static_assert ( bool_constexpr , message ) (since C++11) static_assert ( bool_constexpr ) (since C++17)
Explanation
bool_constexpr - a constant expression that is contextually convertible to bool message - optional (since C++17)string literal that will appear as compiler error if bool_constexpr is false
A static assert declaration may appear at block scope (as a block declaration) and inside a class body (as a m