This is the mail archive of the
mailing list for the GDB project.
Re: [RFA 1/3] Fix "fall through" comments
On Tue, Sep 27, 2016 at 10:10 PM, Tom Tromey <firstname.lastname@example.org> wrote:
>>>>>> "Yao" == Yao Qi <email@example.com> writes:
> Yao> clang has -Wimplicit-fallthrough as well, but warnings are suppressed in
> Yao> a different way. Do we need to suppress warnings generated by both gcc
> Yao> and clang?
> On my machine, clang won't build gdb. From memory there was at least
> some issue compiling .c files in c++ mode, but I think there were other
> problems as well.
We can use option '-x c++' to suppress the warnings, but you are right, there
are some other problems, like some warning options are unknown to clang.
> If clang support is desired, then yes, the correct approach is to
> replace the fall-through comments with a new attribute.
At least, I don't think of a reason that we don't support clang. clang(++)
support is not very good, but we shouldn't make it worse, IMO. I am open
to people's thoughts.