Hacker News new | ask | show | jobs
by jerrre 1698 days ago
I do agree that C++ is a very big and complicated (and ugly) language, and because they value backwards compatibilty the only way it can go is even more complicated, because the cannot strip out stuff.

But you last question can be answered in a couple of directions: 1. you don't HAVE to use C++, if there's another language easier, or better suited to your goals, use that. I think as long as C++ is the best choice for some domains it will stay relevant. 2. you don't HAVE to know/use all features of C++. If you're working solo just ignore the parts you want. If you're in a big team hopefully the codebase is such that you don't need to know everything about it to be productive. 3. Is adding features worth it? Well if you take 1 & 2 in to account, I think the downsides are capped a bit, and the upside is: more options. But of course whether you prefer many options with a lot of complexity, or a straightforward language is subjective.

2 comments

It’s actually fairly rare that you get to choose what language and language features are used in the code base that you’re responsible for. Sure, if you’re the tech lead at a startup, or working on a personal project, but for all my day jobs, I’ve not once gotten to choose anything that fundamental about the code base.

So just in general, I do think it’s fair criticism of a language for offering crappy features, even if it is “optional” to use them. (Not arguing either way for coroutines specifically, as I’m not a c++ dev).

> the only way it can go is even more complicated, because the cannot strip out stuff.

The irony is of course that they have stripped stuff out. I spent a fair amount of time going through an old code base in my last job stripping out std::unary_function and std::binary_function. Not saying that the replacement isn't better however.