Re: Implement -Wimplicit-fallthrough (version 4)

2016-08-22 Thread Martin Sebor
Just a few minor nits based on a quick reading of the patch: @@ -24114,6 +24164,16 @@ cp_parser_std_attribute (cp_parser *parser) " use %"); TREE_PURPOSE (TREE_PURPOSE (attribute)) = get_identifier ("gnu"); } + /* C++17 fallthrough attribute is equival

Implement -Wimplicit-fallthrough (version 4)

2016-08-22 Thread Marek Polacek
This version of -Wimplicit-fallthrough incorporates changes I made to address Jakub's and David's comments. I fixed up the fixit hints handling (the output looks much better now) and added tests for that. I also added tests for ObjC and Obj-C++ and the warning now works for these languages too.

Implement -Wimplicit-fallthrough (version 4): add gcc_fallthrough

2016-08-22 Thread Marek Polacek
Accompanying changes to the core patch. 2016-08-22 Marek Polacek PR c/7652 * Makefile.in (insn-attrtab.o-warn, insn-dfatab.o-warn, insn-latencytab.o-warn, insn-output.o-warn, insn-emit.o-warn): Add -Wno-switch-fallthrough. * builtins.c (expand_builtin_in