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...
"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?
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.
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).
@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++.
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.
"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)
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.
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.