r/programming • • Apr 25 '22

New C++ features in GCC 12

https://developers.redhat.com/articles/2022/04/25/new-c-features-gcc-12
40 Upvotes

4 comments sorted by

5

u/Wide-Tap7452 Apr 26 '22 edited Apr 26 '22

I remember the time when I used to know all rules of C++. Now it's a long-lost battle. (Edit: typo)

2

u/matthieum Apr 26 '22

I always found C++98 complicated enough that I couldn't remember all rules. I could use it, but there was always this weird corner case popping up that I'd force me to dive into the standard and ask around to figure out why something was or wasn't allowed or was behaving like it did. It... went downhill from there.

3

u/flatfinger Apr 27 '22

One problem with all the corner cases in the C and C++ Standards is that the Committees have never demonstrated a consensus understanding of how they should all be handled. If some members of the Committee approved part of the Standard because they thought it defined the behavior of a piece of code, and others approved it because they thought it didn't, it will forever be impossible for anyone to know what that part of the Standard really "means", because there will never be a consensus to resolve the ambiguity.

1

u/palparepa Apr 26 '22

It's been about 12 years since I last used C++ seriously. Reading these new features, I have no idea what most of them are about.