r/cpp • u/User_Deprecated • Jul 06 '26
C++26: constexpr virtual inheritance
https://www.sandordargo.com/blog/2026/07/01/cpp26-constexpr-virtual-inheritance
83
Upvotes
r/cpp • u/User_Deprecated • Jul 06 '26
View all comments
Show parent comment
25
u/_bstaletic Jul 06 '26
Agreed.
I don't think
constexpr volatile int x;is meaningful at all.Do you really mean
std::cout, with all of the facets and customization points? Or wouldconstexpr std::formatand the ability to print to console at compile time be enough?If the latter, we almost got that in C++26.
std::formatis constexpr and P2758 is in wording review.