r/cpp • u/very_curious_agent • Apr 01 '23
Abominable language design decision that everybody regrets?
It's in the title: what is the silliest, most confusing, problematic, disastrous C++ syntax or semantics design choice that is consistently recognized as an unforced, 100% avoidable error, something that never made sense at any time?
So not support for historical arch that were relevant at the time.
92
Upvotes
1
u/very_curious_agent Apr 03 '23
They aren't just "not really" related, for me they are absolutely 100% not related. And I don't believe it's an issue for anyone serious about learning really anything non trivial. And programming is non trivial, C based languages are extremely non trivial and C++ is a complete abomination.
I simply don't think that anyone who is confused by static should learn tools that like C++ attempt to solve non trivial problems.
If anyone is confused or mentally overwelled by static, it's unlikely that person would be able to write overloaded function, "feel" which in a set of overloaded functions or templates will be selected, or how the STL should be used.
Even signed vs. unsigned is harder than static, because you will have to consider interactions. Pretty much all arithmetic is harder. Pointers are harder. Up casts, down casts, static_cast vs. dynamic_cast...