[PATCH 1/2] gdb: replace pragmas with DIAGNOSTIC macros
Simon Marchi
simon.marchi@efficios.com
Thu Dec 2 01:56:11 GMT 2021
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
More information about the Gdb-patches
mailing list