Well, doh. That's a trivially true statement since it depends on the definitions of "correct". From listening to echoes of what happened in and after some of the standardisation attempts, that was non-trivial since the committee members disagreed about what some of the wording meant. Without such agreement, any definition of "correct" is moot. And then similar things happened when the commercial compiler writers asked what sections of the standard meant, because there were, apparently and remarkably, conflicting sections.
Yes, standards as big as the C++ standards will inevitably have ambiguity in places. They are to be fixed in future standards. Many things were cleared up in C++11 for example. The C++ standard is not perfect, and that's why it's still being revised.
I also remember somewhere around 2005 somebody triumphantly announcing the first complete compiler. Now I forget whether it was for C or C++, but since it was 6 years after the standard was fixed, it is plausible that it was for C99. Sorry I can't be more specific.
However, looking at https://en.wikipedia.org/wiki/C99#Implementations it appears that even GCC doesn't fully implement C99 after 15 years!
And then you have languages like Objective-C or Python that don't even have a standard, only a reference implementation. Obviously in this case you'll have a perfect implementation and a perfectly-defined language, by definition! In theory that means all other implementation must also reproduce bugs in the reference implementation.
Of course mere users also have to try and figure out which compilers do/don't "correctly implement" the language - which is an impossible task.
All compilers for all languages have bugs. Are you claiming otherwise?
Again, you are saying "in correctly written code you get correct results", carefully avoiding the issue of whether it is practical to assume that all the code in your system is "correct".
Can you assume that all the code in your system involved in Obj-C compilation are correct? If you can, so can I. All C++ standard libraries included in major compilers have been extensively tested, and finding a bug in the field is extremely rare.
Yes, alternative tools don't allow such things, principally because they have a simpler better foundation where such things aren't necessary.
Like in Objective-C, by basically making const useless?
What, concretely, are you referring to?
Comparing with Java isn't helpful in this case, for the above reason.
Java can definitely be made safer by having a good const ref implementation.
You have an ArrayList of large objects, and you want to let the caller access one element, read-only, without making any copies. How do you go about doing that?
You can't. You have to either trust the caller to not modify the reference you return, or make a copy.
Understanding history is a useful way of determining where skeletons are still concealed, or alternatively of determining that the skeletons have been properly removed.
The language is fully defined by the current standard. All the skeletons are listed, no matter where or how they came about.
I agree.
But those benefits (and many other) should be embodied either in a library, or in a well-defined special-purpose language - possibly one that is converted to plain-vanilla C/C++ for compilation and execution.
Accidentally including them in a general purpose language is a specification and design smell.
Template metaprogramming IS mostly done in libraries (like Eigen). You will rarely see that in application code.
Well, yes, the special-purpose language is the template language. The compiler does convert it to plain-vanilla C++ for compilation.
Would it be better if it was just called a different name and described in a separate document?
I'm sure you and your compiler always produce correct code. Unfortunately most people don't even realise that they are subtly screwing up - and C/C++ baroque complexity is part of that problem.
Yes, C++ is difficult to learn. I don't think anyone is arguing otherwise.
It's a powerful language that can be used to write very elegant (and at the same time, high performance) code by proficient programmers, but it does require more training than most other languages.
Still, there are at least a million C++ developers in the world better than I am, and I can already use C++ effectively and write more elegant code than I can in any other language. So learning C++ to a very practically useful level is far from impossible.