Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Why do people think its too hard to learn? I've been writing in it and learning the new stuff and I'm impressed. Is it just overchoice? Where is all this extra complexity I keep hearing about hiding? Seems to me to keep getting free DLCs that you can optionally learn. Its the language that keeps on giving. My main complaint is the verbosity of it, even with the new stuff which adds brevity like range-based loops. Can someone provide a cooherent example where it was too complex for their needs?


From experience, you’re in the phase of your C++ skill development before you realize all the things you didn’t know you don’t know. Everyone goes through what you’re feeling, and with seniority in the language depression sets in how broken and inconsistent everything is.


Yes, this is me :)

There have certainly been times where I was SMH, thinking "that could have been simpler" maybe that's the beginning of a new phase.


I think the problem you miss (as have I for many years) is that it's not only about you learning the new stuff. When you work in a team, writing "new" C++ code forces everyone to learn the new stuff.

I too enjoy learning the new tools, their tradeoffs and how to best apply them to solve a given problem. But to someone who has not invested this effort (and might even be reading the syntax for the first time), they might as well be reading a completely different language. I believe that is the complexity that is talked about.


That just seems to be a reluctance to learn and stay relevant? You can indeed get away with writing C++98 but the rest of the world keeps turning.

I used to work with a guy who would hate all the "new stuff" and then belittle and berate newbies for not understanding his "simpler" code full of void* and COM code. A bizarre tradeoff of not learning anything new himself for 20 years, and then demanding everyone else knew what he learned 30 years ago. Inflexible. He'd still be using his Amiga if he had his way, cursing every new OS and computer system.

The interesting thing about the newer C++ stuff is that it really does look like a new language - because it is.


This was the complaint I'm curious to dig in to the most.. I suspect it will be divisive. Business goals and life goals don't necessarily align and having to learn a lot and often in order to remain "current" probably runs counter to some goals of businesses/teams where it simply becomes an additional cost.


Have you actually looked at the co-routine stuff? It is another level of awful, even for C++. The committee screwed that up.


You may think you need async, but you don't. This isn't Python or Javascript, the use case for C++ coroutines is microcontrollers and other things without a functioning modern OS.


Until you happen to do modern Windows with WinUI/UWP in C++, as not all APIs are exposed to .NET.


The main target for coroutines was networking. And, given enough library sugar, they actually work decently enough there.

The other use case is generators and there the hard to remove allocation hurts a lot.


This isn't Python. Nobody needs or asked for coroutines to do networking in C++.


many many many people did ask for them.

Also, of course you do not need them. You also do not need C++, just a needle and steady hand.


That is a bold thing to say. Why do you think this is the case?


Not yet, no. I will look out for it. I am definitely I'm in an early phase where I'm just finding things "cool", without noticing why they might be awful. But I do wonder if there are senior devs on each side of the this C++-is-awful fence?


I have done C++ for 15 years, its the only choice in the HFT domain I used to work in. There is nothing that can replace it right now because of its performance, the quality of the compilers and the available library eco-system. But that does not mean that some of C++ corners are not inexcusably obtuse. Co-routines is a new one.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: