r/cpp • u/pavel_v • Mar 27 '26
C++26: A User-Friendly assert() macro
https://www.sandordargo.com/blog/2026/03/25/cpp26-user-friendly-assert
53
Upvotes
r/cpp • u/pavel_v • Mar 27 '26
View all comments
Show parent comment
1
u/Fabulous-Meaning-966 Mar 28 '26
No, UB has a very specific meaning defined by the C++ standard. It does not just mean "the assumptions of your code are violated", it means "the compiler is allowed to do literally anything here". The latter is much worse to debug.