5 ms·
Most times the reason people switch from thing A to thing B is because they have a problem with A. Nobody has a problem with C++. Talk to any C++ dev, they love
by dingo_bat 9y ago
Most times the reason people switch from thing A to thing B is because they have a problem with A. Nobody has a problem with C++. Talk to any C++ dev, they love their job.
- tzhenghao 9y agoNot to mention that there’s huge C++ codebases out there (gaming, financial industries etc.) Great C++ skills will still be in demand for quite a while. Trying to ramp up new developers on a new, “too-bleeding edge” language/framework is too expensive. D markets themselves too hard on the C++ crowd, whereas languages like Rust and Go market themselves well outside the C++ circle to bring those devs closer to something that they can use as part of a performant service imo. I like D, but I think the two other languages stole the spotlight here.
- jstewartmobile 9y agoA 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.
- jchw 9y agoThis I find disagreeable. I love C++ but I've never considered it more than a love hate relationship. Like I believe Bjarne has said, there's an elegant language hiding inside of C++; the problem is, though, that this elegant language is Not C++. Most C++ code I've ever written has at least had some issues with memory or threading, even with the best discipline I've had with C++. I think this is an experience many people share and probably a reason why a lot of folks are so excited for memory-safe alternatives like Rust.