re PR c++/77886 (-Wimplicit-fallthrough: breaks duff's device (in function templates))
authorJakub Jelinek <jakub@gcc.gnu.org>
Mon, 31 Oct 2016 17:10:30 +0000 (18:10 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Mon, 31 Oct 2016 17:10:30 +0000 (18:10 +0100)
commit9782e1ec0aaf2e578ebaf83fc0fa70d67e0fe939
treea7e2d192f9a6fd5143d44bb9836a1ad0487246be
parentc5fed5c6f272f99c9a86eaa63f6c8c142cce0e86
re PR c++/77886 (-Wimplicit-fallthrough: breaks duff's device (in function templates))

PR c++/77886
* pt.c (tsubst_expr) <case CASE_LABEL_EXPR> Copy over
FALLTHROUGH_LABEL_P flag to the new LABEL_DECL.
(tsubst_expr) <case LABEL_EXPR>: Likewise.

* g++.dg/warn/Wimplicit-fallthrough-2.C: New test.

From-SVN: r241711
gcc/ChangeLog
gcc/cp/ChangeLog
gcc/testsuite/ChangeLog