On 5/20/21 4:05 PM, Jonathan Wakely wrote:
On 19/05/21 23:52 +0100, Jonathan Wakely wrote:
On 19/05/21 16:08 -0400, Jason Merrill wrote:
On 5/19/21 4:05 PM, Jonathan Wakely wrote:
Oh, also we have https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93769
which points out a problem with the current wording. Not a very
important one, but still ...
While I'm touching all 38(?) places that say "only available with
-std=c++NN or -std=gnu++NN I could change them to say something like
"only available since C++NN". Should I bother?
Clang's equivalent warnings say "are a C++11 feature" e.g.
ext.C:1:17: warning: inline namespaces are a C++11 feature
[-Wc++11-inline-namespace]
(They have a specific warning for each feature, with
-Wc++11-extensions to control them all at once.)
The clang wording seems more accurate, as that PR points out.
OK, that requires touching a number of error_at and inform calls as
well as the pedwarns, so I'll address that separately in a later
patch.
Here's a WIP patch that rewords all those diagnostics. This doesn't
include the necessary testsuite changes, and I don't know when I'll
have time to do the rest of it. But it's a start. Does this look like
the right approach?
+ "trailing return type is a C++11 feature");
...
+ "%<constexpr%> destructors are a C++20 feature");
I wonder if we want to standardize on singular or plural.
I wonder if we want to keep the mention of the -std= option, possibly
also mentioning the currently active standard level.
Jason