"C++ Sucks" - Why?

Pages: 1... 345
Jan 2, 2013 at 9:59pm
closed account (z05DSL3A)
"There are only two kinds of programming languages: those people always bitch about and those nobody uses." -- Bjarne Stroustrup
Jan 2, 2013 at 10:14pm
closed account (N36fSL3A)
I didn't mean to start a flame war... I'm just going to step away from this topic for a bit until you guys cool down. I don't want to get anyone more angrier...
Jan 2, 2013 at 10:26pm
@Grey Wolf, sorry, you're too late. Cubbi already posted that a while ago. I think this quote should only be allowed once per thread...

@Fredbill, who's flaming?
Jan 2, 2013 at 10:46pm
closed account (z05DSL3A)
It's never too late or too often for that to be said. :0)

I also haven't been following this thread, just keep seeing it floating to the top.
Jan 3, 2013 at 12:11am
closed account (N36fSL3A)
I ment an argument.
Jan 3, 2013 at 2:18am
At least now I know I can bug rapidcoder for help when it comes to my learning Java ;).
Jan 3, 2013 at 10:55am
"There are only two kinds of programming languages: those people always bitch about and those nobody uses." -- Bjarne Stroustrup

This is so obvious and so useless then I have a hard time thinking about what you guys find so exciting about this quote. Is Bjarne really suggesting we shouldn't ever discuss anything?
Jan 3, 2013 at 11:25am
closed account (z05DSL3A)
Is Bjarne really suggesting we shouldn't ever discuss anything?
To me it just means all programming languages have their flaws that people are going to bitch about. If no one is bitching about language X then it is because no one is using it and not because it is a good language.

So to answer "C++ Sucks" - Why?, all languages suck in some regard.
Jan 3, 2013 at 11:37am
Absolutely, nothing is perfect. But this is not a response I would like to see if someone raises a valid argument against something.
Jan 3, 2013 at 1:47pm
Both the popularity of C++ and its complexity and other supposed flaws are the direct result of its goals, which it achieved and over-achieved despite zero budget and many competing interests. It could have been much simpler, but nobody would use it (see D).
Jan 3, 2013 at 2:32pm
@Cubbi, I don't think the comparison with D is fair. Do you not feel that Java is simpler than C++ (and plenty popular)? Also, could you list the goals of C++.
Jan 3, 2013 at 3:23pm
I don't think comparison with Java makes any sense, to be honest. Java is just too fundamentally different (despite the occasional attempts to stretch it into C++'s domain -- it fails miserably in practice)

C++'s goals evolved slightly over time. It started as a combination of three things:
1. Simula-style OOP (note, not Smalltalk-style like in Java)
2. Stepanov's generic programming
3. A better (safer, faster, and more managable) C
Today it is the lightweight abstraction programming language for software infrastructure and resource-constrained applications. Its key strengths are integrated resource management and error handling and extensive strong static typing.
Last edited on Jan 3, 2013 at 3:24pm
Jan 3, 2013 at 4:16pm
I wouldn't call C++ lightweight. C++ programs, maybe, but not the language itself.
Last edited on Jan 3, 2013 at 4:16pm
Jan 3, 2013 at 4:47pm
"lightweight" is the qualifier to "abstraction" in that sentence. C++ abstractions don't add overhead (and often remove it, as in case of functors/lambdas)
Jan 3, 2013 at 4:52pm
Java is Simula flavored. It would be almost unrecognizable to C++ programmers if it was Smalltalk flavored, which would have been against its design goals.
Jan 3, 2013 at 5:22pm
C++ abstractions don't add overhead (and often remove it, as in case of functors/lambdas)


This is interesting - are lambdas passed from a different compilation unit, inlined? If not, then I wouldn't call it no-overhead.
Jan 3, 2013 at 5:50pm
Some C++ abstractions add overhead: think about templates. The compiler has to generate the same code for every type (or set of types in the case of templates with multiple type parameters) that the template is used for, and that's only in a single source file. If the compiler doesn't optimise it away, the exact same function could appear in each file, leading to a larger executable, which could decrease performance.
Topic archived. No new replies allowed.
Pages: 1... 345