4 ms·
> C++ is a big, complex language And therein lies the actual problem. C++ killed the one saving grace of C, it's relative simplicity, and created a language t
by dkjaudyeqooe 3y ago
> C++ is a big, complex language
And therein lies the actual problem. C++ killed the one saving grace of C, it's relative simplicity, and created a language that is a dumping ground of ideas.
The notion that you just "learn what you need" is an anathema. Not knowing a language, and all it's subtleties, is just a form of hacking. You end up encountering things which you don't understand and have to hope you don't cause unknown problems and muddle through.
That C++ is widely used by professionals who don't understand their tools is just another reason why software is so crappy these days.
- brandall10 3y agoRight... doing that specialized subset of a language that makes sense for you might not make sense for your team, might not make sense for your next team, and so on.
- Aeolos 3y agoPlus, every library is using a different subset, so it’s not as if you can stay within your preferred subset either. I worked in a project that had 6 different string classes: std::string, opencv, vtk, qt … plus a wrapper around all of the above that converted this mess to a plain C string so you could actually use it. A real nightmare, with no good way out. I’m sure some C++ person will say “it’s not the fault of the language, it’s simply that those libraries are not proper C++23”, missing the fact that those are some of the most prolific, well-maintained and widely used projects in the C++ world. If even those can’t get it right, then the problem must surely lie with the underlying language itself, and with the committee who is defining how it’s supposed to work.
- jcelerier 3y ago> If even those can’t get it right, Most likely they do get it right for their problem domain. If the people who made opencv, vtk and qt had to make it in another language with the design constraints they had (which can sometimes be as simple as insisting on using CamelCase instead of snake_case for historical reasons) they would likely make their own string / array / matrix / ... type in that language too tailored to their exact problem domain.
- MaxBarraclough 3y ago> C++ killed the one saving grace of C, it's relative simplicity, and created a language that is a dumping ground of ideas. I think the average C++ programmer is pretty aware of the language's downsides. It's still a language with important practical upsides though: there are plenty of C++ programmers out there for hire, there are many existing C++ projects that need to be worked on, and it has a strong ecosystem of compilers and libraries. There seems to be little prospect of C++ losing its near-monopoly in core game-engine code, for instance. (I say all this as someone who usually gives C++ a hard time for its poor safety, and associated security issues.) > That C++ is widely used by professionals who don't understand their tools is just another reason why software is so crappy these days. No doubt there are many security issues with those roots, and many instances of code that's needlessly non-portable. Those are due to specific issues with C++ though, not its general complexity. I imagine the practical consequence of the language's complexity is to drag out development times, rather than to undermine software quality. I haven't given this too much thought though, and this is essentially a guess. > The notion that you just "learn what you need" is an anathema. I agree this idea makes little sense. If you work in a team, you may be asked to debug someone else's code. If you're going to work with C++, there's no denying the value in having a deep knowledge of the language.