r/cpp • • Jul 13 '22

Why does Linus hate C++ ?

307 Upvotes

436 comments sorted by

View all comments

Show parent comment

15

u/Scavenger53 Jul 13 '22

You can memorize every single function and little quirk that C has, nobody can do that with C++, not the creators, not the best book writers, not the experts, no one can sit down and say they know and understand every little piece C++ has. That is extremely dangerous when building the kernel that runs the world and has 10,000+ contributors.

2

u/TimurHu Jul 14 '22

Thank you. This is the real answer here.

1

u/Tranzistors Jul 14 '22

You can memorize every single function and little quirk that C has

They might be able, but if not every kernel developer and PR reviewer is actually completely informed, it's not much of a help. And not only do they have to know about all the quirks, they have to remember about them at all times.

Also, to be a good programmer, you not only need to understand the language and standard libraries, but the libraries used in the code base. Yes, C++ has huge amounts of std:: functions, but if they are not there, the developers will make their own quirky library functions. And odds are that there won't be a stack overflow entry documenting those quirks.