Archive for October, 2023
The constinit specifier, introduced in C++20, is applied to static variables (global and local static) and thread local variables, with the requirement that they either have a zero initialization or they are initialized with a compile-time constant expression. Here is our first example: Line 17 declares a global constinit variable, initialized with a constant value. […]
Recent Comments