This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 0/5] Remove a few hurdles of compiling with clang


On 06/12/2017 05:23 PM, Andrew Pinski wrote:
> On Mon, Jun 12, 2017 at 8:54 AM, Simon Marchi <simon.marchi@polymtl.ca> wrote:

>>  - gdb: Add -Wno-mismatched-tags: We already have a system that tests which
>> warning flags are supported by the current compiler, so this flag will not
>> be included in the builds with GCC.  So it's neutral for GCC, and improves
>> the situation for Clang with almost no effort.
> 
> This warning is a bug in clang and really should not be warned about
> in either -Wall or -Wextra.  I have been complaining about this since
> clang added this option.

IIRC, the reason this warning exists is because Microsoft's compilers
mangle "struct" and "class" differently, so for projects that
want to be portable to that compiler, it's a helpful warning.
(Whether that should ever be part of -Wall is a separate matter...)

I don't think we'd want to bend backwards to support MSVC
though.  It's so non-conforming that it's scary.  Disabling
that warning is the right thing to do, IMO.

Thanks,
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]