Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Why is C++...

Name: Anonymous 2011-12-07 12:06

...so bad? Why does it have such a bad reputation?

I'm an experienced C++ programmer and, while the language has warts, I can't understand the reason for the enormous amount of criticism against the language.

I'd like to hear the honest opinions of /prog/rammers in this regard.

Name: Anonymous 2011-12-08 10:36

>>44
Good. Thus we might exclude every modern programming language, including C, Java and almost every scripting language out there.

How old are you, by the way?

>>47
I've read it elsewhere, and commented on it. I'll not repeat the entire argument, but just restate that this guy must be living on a reality bubble. He abuses terminological ignorance ("epistemological process"), unwarranted personal judgements and assertions ("C++ is a language strongly optimized for liars and people who go by guesswork and ignorance"), and even poetic verbosity ("C++ has taken premature optimization to the level of divine edict"), instead of trying to analytically pose arguments in his favor.

In other words, his text has a particular effect on people which are already influenced and particularly biased to accept that sort of criticism -- that's exactly the goal of his text. It is not to help forming an opinion, but rather exalt and praise an already present one, inside people without the verbal talent to express it the way he did.

And, as most teenagers, he doesn't even bother writing properly, and jot funky rebel signatures in his emails. In plain English, the guy's simply an immature neckbeard. Too bad he claims himself to be a Lisp hacker: it just helps further mar the image of the average Lisp programmer, in detriment of the very few sane (and socially capable) ones.

For good C++ criticism, Yossi Kreinin's FQA is a much better read, in every aspect. Specially because Marshall Cline's FAQ, its antagonist, is a terrible read: he is arrogant, yield unfunny jokes, and sometimes outright lie to the reader. He wears that damned sort of "expert aura" which has also contributed for the bad reputation of C++, making it sound as a language for pedants and help stratifying the programming community into castes.

>>48
Not really, the compiler already detects such cases. True, the C++ grammar is much harder to parse than the C grammar, but, fortunately or not, that problem has already been solved. GCC, for example, is particularly retarded: ever noticed the "each undeclared identifier is reported only once for each function it appears in" (which happens in C and in C++) messages it spits you, sometimes uselessly consuming three lines in your screen? The message's intent is probably to avoid build log pollution, but that's exactly what it does. This is just an example: that's the compiler team's way of being "helpful" to the programmer.

>>52
The fact that most C++ programmers restrict themselves to some subsets of the language is actually necessary, and rather intentional. Concerning the fact that the language contains a lot of different thinking models imbued in it, it is good that a program is itself restricted to a couple of these models, instead of attempting to apply all of them in the same program, which would be awkward and difficult to understand. Whether a language with such characteristics ("multiparadigm", in buzzwords) is itself "good", is just another matter.

Uglyness and complications are highly subjective factors. The C++ syntax I consider ugly is related to the standard libraries and to legacy C constructs, but in general I find it much pleasant to read than Java or Python code, for that's sake. The C++ syntax fits quite well for its purposes.

I like minimalism. I enjoy the idea of taking instead of putting, of having less instead of more. It fits my style, but that's not the point -- I'm not applying personal judgements to a piece of work as it appeals to me, but rather try to evaluate it as it is, in the context where it was intended to fit in. C++ was not meant to be minimalistic; stating it is not so is just reiterating a known fact, and remarking that it is (therefore) bad falls within the scope of subjectiveness and personal opinion.

C++ is indeed old: thread support just came in with C++11, and it still lacks a lot of important things for proper application development, such as networking support. This is, nonetheless, a characteristic of the (official) standardizing process, specially because one of its goals is to provide a lowest common denominator between all platforms the language is intended to target. It follows the C mentality of "if PDP-11 doesn't have it, C++ doesn't have it either". Most C programs are non-compliant, as most C++ programs are.

Aside the entire toolchain problem, one point also worth noticing is that there is a relative lack of good libraries for C++ (and there ain't nothing such as POSIX for further extend the possibilities). Boost is always there, but I personally don't consider it to be a good library.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List