This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH RFA: Permit backward/hash_map with -Wdeprecated
Paolo Carlini <pcarlini@gmail.com> writes:
>> Bootstrapped and ran libstdc++ testsuite on i686-pc-linux-gnu. OK
>> for mainline?
>
> I'm away from my primary development machine and cannot check the
> whole logic behind those macros, but first blush I'm not ok with the
> patch. *When* are we going to warn, with the patch applied? Because
> morally this stuff *is* deprecated, and that is already a concession.
> If essentially we are going to never warn, then let's move back this
> stuff to ext/, seems much cleaner to me. I have no problem with the
> other maintainers overruling me about these issues, but really
> personally I'm not confortable with extending the life of this old
> code, simply we don't have the manpower to care about legacy stuff,
> with all the work ahead of us for C++1x!
With the patch applied, the warning will continue to occur by default
just as it does today. The warning will not occur if the program
first defines _GLIBCXX_PERMIT_BACKWARD_HASH before #include'ing the
files. That is, this patch does not change the default behaviour. It
provides a hook for a program to disable the warning for this specific
header files. In practice this would be used via a project specific
header file which defines the macro and the #include's the libstdc++
header file.
I of course understand the manpower argument but I don't think it
applies here. Nobody is expecting the libstdc++ maintainers to fix
bugs in this old code.
Ian