[C++ PATCH] Deprecate ARM-era for scopes

Nathan Sidwell nathan@acm.org
Tue Jan 23 12:27:00 GMT 2018


As discussed (https://gcc.gnu.org/ml/gcc-patches/2018-01/msg01778.html) 
this patch deprecates the ARM-era for scope.

a) in c++98 mode with -fpermissive, there's now a deprecation note when 
we fix up something like
    for (int i = ...) {}
    ... i ... // out of scope use of i

b) -fno-for-scope gives a deprecated warning

I noticed that the flag showed signs of being tri-valued at some point, 
but it is no longer (I suspect at some point we only attempted #a if 
neither sense of -ffor-scope was given).  Cleaned that up.

Applying to trunk.

nathan
-- 
Nathan Sidwell
-------------- next part --------------
A non-text attachment was scrubbed...
Name: for-scope.diff
Type: text/x-patch
Size: 7926 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20180123/d2da0d5f/attachment.bin>


More information about the Gcc-patches mailing list