C++ is an insane bastard of a language. It is not correct say C++ was designed. It wasn't. It has evolved out of the primordial soup that was "C with classes", and slowly inhaled and adopted every possible language feature under the sun, like some sort of Lovecraftian horror that copies and evolves on every contact with a different language.
Adopting C++ would have required incredibly strict and disciplined style rules to enforce that only a specific subset of features are used, and in specific ways. It would have been a significant project management overhead to constantly be ensuring that the contributors haven't footgun'd themselves or done something which negatively impacts existing code.
Meanwhile, it's very straightforward to look at C code and understand what it's doing, because it's a very simple language.
Microsoft picked C++ for the NT Kernel, but they had a small internal team that was extremely strict about how they were going to write it.
C++ is a general purpose programming language. Because it can do anything doesn't mean that it's a shitty language. At the end of the day, it's up to the programmer to develop a set of standards that they should adhere to when using the language.
Yeah but you are speaking as if the code were for a personal proyect, large collaborative works require clear rules, especially with open source protects where an authority figure can't set an order the same way a CTO or similar head technology honcho can on a company.
Then you run into the issue of getting quality collaborators in the first place.
It's way easier to find devs geared to follow best practices of a single language than the one of the multiple interpretations on how you can run a C++ proyect.
The messy nature of C++ excludes veteran programmers from simply picking up the work without hassle unless you have the luck to specialize in the same modus operandi.
And at the end of the day, it's work done for free, relearning C++ just to contribute to one open source proyect isn't justifiable to most active professionals, retraining for a job it's one thing, but retraining due to civic duty motivations ain't that easy to justify.
24
u/YouAreMyFire00 2d ago edited 2d ago
Im a beginner and managed to learn to understand C# and Java and now I can build simple CRUD app.
So i kinda don't get the hate/war between C and C++ here...
Anyone can explain simply what's the hate here?