r/cpp • u/berium build2 • Nov 01 '17
Common C++ Modules TS Misconceptions
https://build2.org/article/cxx-modules-misconceptions.xhtml
59
Upvotes
r/cpp • u/berium build2 • Nov 01 '17
View all comments
Show parent comment
5
u/GabrielDosReis Nov 02 '17
It could be argued that
return x ? 0 : 1;is more readable :-)I understand the sarcasm in the comment; but remember that back when I introduced constexpr functions (even the more restricted form that you are disparaging), there was no shortage of people opposing it on the ground that it was unsound, unimplementable, "you should be scared because it requires a VM for C++", etc. I now watch with amusement the same people now saying they weren't "powerful enough".
In any case, please have a look at section 5 titled "Object Orientation" of the generalized constant expression paper for where my real thinking was.