c-parser.c (c_parser_switch_statement): Add IF_P argument, parse it through to c_pars...
authorJakub Jelinek <jakub@redhat.com>
Thu, 5 May 2016 13:26:59 +0000 (15:26 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 5 May 2016 13:26:59 +0000 (15:26 +0200)
commit351f85c5be3287b3ab495195ff15c5fedf09303f
treeb1c40179c0f161d00823019b5aa3295ab05f47ee
parentf5c40ce2cf8812d28e4738143a491bd77c0a0ce0
c-parser.c (c_parser_switch_statement): Add IF_P argument, parse it through to c_parser_c99_block_statement.

* c-parser.c (c_parser_switch_statement): Add IF_P argument,
parse it through to c_parser_c99_block_statement.
(c_parser_statement_after_labels): Adjust c_parser_switch_statement
caller.

* parser.c (cp_parser_selection_statement): For RID_SWITCH,
pass if_p instead of NULL to cp_parser_implicitly_scoped_statement.

* c-c++-common/Wdangling-else-4.c: New test.

From-SVN: r235920
gcc/c/ChangeLog
gcc/c/c-parser.c
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/Wdangling-else-4.c [new file with mode: 0644]