[clang] [C23][Parser] Diagnostic for attribute declaration where statement is required (PR #146224)

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 1 11:21:54 PDT 2025


================
@@ -35,7 +36,7 @@ void f(int n) {
       [[fallthrough]];
     }
   case 8:
-    [[fallthrough]]; // expected-error {{does not directly precede switch label}}
+    [[fallthrough]]; // FIXME: The error {{does not directly precede switch label}} cannot reproduce in this translate unit, But it can be reproduced in a separate file.
----------------
AaronBallman wrote:

Huh, I wonder what's going on there...

https://github.com/llvm/llvm-project/pull/146224


More information about the cfe-commits mailing list