[PATCH 1/2] gdb: replace pragmas with DIAGNOSTIC macros
Simon Marchi
simon.marchi@polymtl.ca
Thu Dec 2 02:44:25 GMT 2021
On 2021-12-01 20:56, Simon Marchi via Gdb-patches wrote:
> On 2021-12-01 19:09, Tom de Vries wrote:
>> On 11/23/21 10:14 PM, Simon Marchi via Gdb-patches wrote:
>>> When introducing this code, I forgot that we had some macros for this.
>>> Replace some "manual" pragma diagnostic with some DIAGNOSTIC_* macros,
>>> provided by include/diagnostics.h.
>>>
>>> In diagnostics.h:
>>>
>>> - Add DIAGNOSTIC_ERROR, to enable a diagnostic at error level.
>>> - Add DIAGNOSTIC_ERROR_SWITCH, to enable -Wswitch at error level, for
>>> both gcc and clang.
>>>
>>
>> I think you forgot the default definition
>> ...
>> #ifndef DIAGNOSTIC_ERROR_SWITCH
>> # define DIAGNOSTIC_ERROR_SWITCH
>> #endif
>> ...
>>
>> Otherwise, LGTM.
>>
>> Thanks,
>> - Tom
>
> Right, fixed locally.
>
> I would just like to get an Ack from a binutils maintainer, if possible,
> since this touches the include directory.
>
> Simon
>
Actually, I posted a v2 which obsoletes this patch, see:
https://sourceware.org/pipermail/gdb-patches/2021-December/184043.html
Simon
More information about the Binutils
mailing list