diff options
author | Alexander Kornienko <alexfh@google.com> | 2013-01-25 15:49:34 +0000 |
---|---|---|
committer | Alexander Kornienko <alexfh@google.com> | 2013-01-25 15:49:34 +0000 |
commit | 5548879324813b8fa74d1c67e08a2e00ead7785f (patch) | |
tree | 4306b8fc350c624696e264e26a7c76c4a83e9f2b /clang/test/SemaCXX/switch-implicit-fallthrough.cpp | |
parent | 7a31af140b3a7beada378700a4795e38dd886188 (diff) | |
download | bcm5719-llvm-5548879324813b8fa74d1c67e08a2e00ead7785f.tar.gz bcm5719-llvm-5548879324813b8fa74d1c67e08a2e00ead7785f.zip |
Don't suggest to insert [[clang::fallthrough]] before empty cases. Fix for multiple case labels.
llvm-svn: 173458
Diffstat (limited to 'clang/test/SemaCXX/switch-implicit-fallthrough.cpp')
-rw-r--r-- | clang/test/SemaCXX/switch-implicit-fallthrough.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/switch-implicit-fallthrough.cpp b/clang/test/SemaCXX/switch-implicit-fallthrough.cpp index cfc29c237c2..75dda8a9617 100644 --- a/clang/test/SemaCXX/switch-implicit-fallthrough.cpp +++ b/clang/test/SemaCXX/switch-implicit-fallthrough.cpp @@ -34,6 +34,8 @@ int fallthrough(int n) { case 6: // expected-warning{{unannotated fall-through between switch labels}} expected-note{{insert '[[clang::fallthrough]];' to silence this warning}} expected-note{{insert 'break;' to avoid fall-through}} n += 300; case 66: // expected-warning{{unannotated fall-through between switch labels}} expected-note{{insert 'break;' to avoid fall-through}} + case 67: + case 68: break; } switch (n / 20) { |