According to cppreference, assert
will be used as a C++ attribute.
However, there already exist tons of projects heavily dependent on the macro assert
, is there any bad effect?
No. The proposal p0542r5 which introduces C++20 contracts says:
Note that while
assert(expression)
would expand as a function-like macro with the appropriate header,assert:
is not a function-like invocation, so does not expand.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With