News for hackers. Stuff that matters.
Re:Rust 2019 and beyond: limits to some growth by klodolph on Thursday December 27, 2018 @07:14PM (#18773837)
I would disagree with the claim that “C++98 isn’t all that complex.” It was so complex that any project I found using it would restrict itself to some arbitrary subset, just to keep complexity under control. Java has gone through years of backwards-compatible changes, and is still wonderfully simple compared to early versions of C++. C++ started with a mess of different features and hasn’t really gotten worse. If anything, C++11 is simpler than C++98 from a user’s perspective, even though it’s not from an implementer’s perspective.

One of the big differences is that Java and Go have straightforward context-free grammars, mostly, and you can whip up a working parser in no time. C++ is a bit of a beast, by comparison (hence keywords like “typename”).

C++ also has the complex overloads and template system. I think people underestimate how complex these things are when they are learning C++, and how complex their interactions are. Then there’s the preprocessor.

You can kind of argue that these are just an accumulation of changes, but other languages contemporary with C and C++ do not suffer from these complexities, so the argument falls flat. By comparison, Go and Java rely on reflection or code generation more, and these are a bit simpler.

Re:Rust 2019 and beyond: limits to some growth by shmerl on Thursday December 27, 2018 @08:49PM (#18774296)
> I think people underestimate how complex these things are when they are learning C++, and how complex their interactions are. Then there’s the preprocessor.

And then there is arcane stuff like this:

* https://en.cppreference.com/w/cpp/language/eval_order

* https://en.cppreference.com/w/cpp/language/copy_elision

That does make the language feel very complex even without the whole templates depth.