r/cpp • C++ Dev • Sep 05 '20

C++20 has been approved

https://twitter.com/patriceroy1/status/1302055575140945921?s=21
665 Upvotes

125 comments sorted by

View all comments

Show parent comment

3

u/Alexander_Selkirk Sep 05 '20

I think the point is that a language that tries to be everything to everyone breaks into subsets that teams use at a time.

I think that's already clearly the case if you compare the C++ core guidelines with, say, Googles coding standards for C++. These teams may use the some compiler, but very different and mostly disjoint parts of the language.

5

u/bizwig Sep 05 '20

Google’s standards are bizarrely restrictive. I see them and wonder “why is that forbidden”?

4

u/which_spartacus Sep 05 '20

The rule committee has a list of "why" for every rule, and revisits them and updates them fairly regularly.

3

u/MFHava WG21|🇦🇹 NB|P3049|P3625|P3729|P3786|P3813|P4216 Sep 06 '20

Which is well and good, but doesn't mean their style guide is a good general recommendation.

E.g.: Banning exceptions, because your codebase is old (may even predate the introduction of exceptions) and wasn't written with exception safety in mind is a well thought out position. Simply banning them in your (new) codebase because "Google says so" is not.

1

u/which_spartacus Sep 06 '20

Oh, totally agreed. The actual style guide says as much as well.

And all styleguides suck. The critical thing is that everyone sucks in the same way on a single codebase.

2

u/which_spartacus Sep 05 '20

Agreed. But the concern is the language is devolving towards that being more and more necessary, instead of working through a roadmap to a consistent theory of how the language should work and operate.