4 ms·
A long time ago, I did C++ dev for about 5 years. Absolutely hated it. Part of that could have been that it was C++ for Windows, but even so... Slow compile
by jstewartmobile 9y ago
A long time ago, I did C++ dev for about 5 years. Absolutely hated it. Part of that could have been that it was C++ for Windows, but even so...
Slow compile times, a sea of compiler options, pragmas, swamps of macros and templates, and the complete lack of understanding among coworkers of OO concepts like virtual functions or inheritance.
Can totally sympathize with Linus' contempt for C++.
edit: Notice dingo_bat is getting downvoted on this. How about responding with why you dislike C++ instead of the downvote?
- thesmallestcat 9y agoBut C doesn't have virtual functions or inheritance either.
- jstewartmobile 9y agoWhich isn't that much of a problem. When that approach is truly called for, you can fake it well enough in C with function pointers and macros. I know that isn't easy. If it makes you think first, sometimes "not easy" is a net positive. With "easy" OOP, the typical result was a wad of tightly-coupled classes that were difficult to enhance or reuse. C++ jammed so many different concepts into the built-ins, catering to all yet pleasing none. Last I checked, exceptions were still kind of a mess. Places I know that still use it have their own peculiar commandments as to what is halal and what is haraam. I do not blame them.
- abcd_f 9y agoIf you use C++ as "C with Classes", it is a fantastic C replacement. Just stick to 'struct's instead of 'class'es, use ctor/dtor for RAII, pure virtual functions to declare interfaces and single-level inheritance to implement them and, perhaps, an occasional template to replace a macro - and you still basically have C, but it's now far less verbose and more pleasant to use.
- jstewartmobile 9y agoFair enough, but how many train wrecks did you have to witness to come to that conclusion?
- abcd_f 9y agoHehe... in my case there was some oscillation between C and C++ before eventually converging to C-style C++. To each his own. I even heard of people who thought Boost was a good thing, but I suspect someone was making a joke.
- AstralStorm 9y agoBoost is being surpassed by new standards though. Most of the truly and widely useful stuff from boost is being reimplemented in a much cleaner way for standard library. It can be considered proving ground.