PR c/c++/diagnostics/66098 Take -Werror into account when deciding what was the command-line status

Jeff Law law@redhat.com
Tue Aug 11 19:53:00 GMT 2015


On 08/10/2015 08:37 AM, Manuel López-Ibáñez wrote:
> PING^2: https://gcc.gnu.org/ml/gcc-patches/2015-07/msg02581.html
>
> On 3 August 2015 at 20:47, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote:
>> PING: https://gcc.gnu.org/ml/gcc-patches/2015-07/msg02581.html
>>
>> Thanks,
>>
>> Manuel.
>>
>> On 30 July 2015 at 17:35, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote:
>>> When I fixed PR59304, I forgot that a command-line warning can be also
>>> an error if -Werror was enabled. This introduced a regression since
>>> anything enabled in the command-line together with -Werror would get
>>> initially classified as a warning when reaching the first #pragma GCC
>>> diagnostic, and this will be the setting after a #pragma pop.
>>>
>>> Options that appear as arguments of -W[no-]error= are not affected by
>>> this since those are initially classified as errors/warnings even
>>> before reaching the first #pragma, thus the pop sets them correctly
>>> (before and after this patch). Nonetheless, the tests also check that
>>> they work correctly.
>>>
>>> Boot&regtested on x86_64-linux-gnu.
>>>
>>> OK?
>>>
>>>
>>> gcc/ChangeLog:
>>>
>>> 2015-07-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
>>>
>>>      PR c/66098
>>>      PR c/66711
>>>      * diagnostic.c (diagnostic_classify_diagnostic): Take -Werror into
>>>      account when deciding what was the command-line status.
>>>
>>> gcc/testsuite/ChangeLog:
>>>
>>> 2015-07-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
>>>
>>>      PR c/66098
>>>      PR c/66711
>>>      * gcc.dg/pragma-diag-3.c: New test.
>>>      * gcc.dg/pragma-diag-4.c: New test.
OK
jeff



More information about the Gcc-patches mailing list