News for hackers. Stuff that matters.
Re:Why not C++? by jacques_chester on Saturday March 05, 2016 @02:37PM (#11230679)
Summarising how I usually seeing these discussions go:

The usual argument goes that C++ is bad because of the problems of C.

The counter-argument is that "nobody does that in modern C++".

The counter-counter argument is that:

1. there's a lot more not-modern-C++ than there is modern C++.

2. there seem to be dozens of not-really-smoothly-interchangeable notions of what "modern C++" is, because the language is so vast, and there have in fact been several overlapping generations of "modern C++".

3. It still requires conscious and vigilant effort, over and above the baseline the language gives you, to not introduce game-over security or reliability flaws.

The counter-counter-counter argument is that these are true of every language.

Which, being not strictly and completely true in the particulars, is where the whole thing degenerates into personal reflections about $PET_LANGUAGE, hair-pulling, personal insults, blog posts about monads at twenty paces etc etc.

Re:Why not C++? by kbenson on Saturday March 05, 2016 @02:49PM (#11230740)
> The counter-counter-counter argument is that these are true of every language.

I think the problem is that people keep treating these as binary attributes in some cases (usually the ones counter to their argument), and gradient ones in other cases, and this doesn't lead to effective communication. Almost all the attributes are gradient. The question is not whether C++ takes conscious and vigilant effort to not use a footgun, it's how much conscious and vigilant effort it takes in in comparison to an alternative, and for an alternative, it's not just that it may be slower, but how much slower.

Re:Why not C++? by MAGZine on Saturday March 05, 2016 @02:43PM (#11230711)
> 2. there seem to be dozens of not-really-smoothly-interchangeable notions of what "modern C++" is, because the language is so vast, and there have in fact been several overlapping generations of "modern C++".

Everyone I've talked to understands modern C++ to be C++11 or newer.

Re:Why not C++? by titanomachy on Saturday March 05, 2016 @05:04PM (#11231282)
C++11 adds to the language, but is there a strong consensus on what parts of pre-2011 C++ are not allowed in "Modern C++"? I have seen C++ code advertised as "modern" that still uses naked pointers, for example, while others claim that all pointers should be reference-counted. There is no agreed-upon algorithm that answers the question "is this source file written in valid Modern C++?", because there's no agreement on what that means.
Re:Why not C++? by static_noise on Saturday March 05, 2016 @03:26PM (#11230921)
I think that line of arguing misses an important point.

"modern" C++ is the best language we have that holds backwards compatibility with C and old C++ and the humongeous codebase that comes with that.

For many uses that backwards compatibility is of key importance. Therefore C++ does not really have to compete with other languages that don't have that kind of backwards compatibility.

If you want to sort languages into "good" and "bad" you first have to define the use case. Most languages are best at their own respective niches. To cover a large ground, in large project C++ is often combined with scripting languages like Python and Lua to get the best of both worlds.

Re:Why not C++? by dave2000 on Saturday March 05, 2016 @03:35PM (#11230963)
"there's a lot more not-modern-C++ than there is modern C++."

I'm not sure where this statement belongs. In a decision about which language is best suited for a project?

Re:Why not C++? by jacques_chester on Saturday March 05, 2016 @05:54PM (#11231490)
In that saying "none of this is a problem with modern C++" doesn't magically update all the libraries you'll make use of.
Re:Why not C++? by dave2000 on Saturday March 05, 2016 @06:16PM (#11231568)
Ah - libraries. Never used any outside of the standard ones supplied with the compiler, and I've never felt the urge to look at the source of those.