diff options
-rw-r--r-- | data/glr.c | 4 | ||||
-rw-r--r-- | data/lalr1.cc | 4 | ||||
-rw-r--r-- | data/yacc.c | 4 |
3 files changed, 5 insertions, 7 deletions
@@ -635,8 +635,8 @@ yytnamerr (char *yyres, const char *yystr) if (*++yyp != '\\') goto do_not_strip_quotes; /* Fall through. */ -#if defined(__has_cpp_attribute) && __has_cpp_attribute(clang::fallthrough) - [[clang::fallthrough]]; +#ifdef __cplusplus + [[fallthrough]]; #endif default: if (yyres) diff --git a/data/lalr1.cc b/data/lalr1.cc index c6e19777..06f0dedf 100644 --- a/data/lalr1.cc +++ b/data/lalr1.cc @@ -376,9 +376,7 @@ do { \ if (*++yyp != '\\') goto do_not_strip_quotes; /* Fall through. */ -#if defined(__has_cpp_attribute) && __has_cpp_attribute(clang::fallthrough) - [[clang::fallthrough]]; -#endif + [[fallthrough]]; default: yyr += *yyp; break; diff --git a/data/yacc.c b/data/yacc.c index 17ad67c0..0f881d8d 100644 --- a/data/yacc.c +++ b/data/yacc.c @@ -1209,8 +1209,8 @@ yytnamerr (char *yyres, const char *yystr) if (*++yyp != '\\') goto do_not_strip_quotes; /* Fall through. */ -#if defined(__has_cpp_attribute) && __has_cpp_attribute(clang::fallthrough) - [[clang::fallthrough]]; +#ifdef __cplusplus + [[fallthrough]]; #endif default: if (yyres) |