[PATCH] D66487: Fix -Wimplicit-fallthrough warnings in regcomp.c
Aaron Ballman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 20 12:29:59 PDT 2019
aaron.ballman added inline comments.
================
Comment at: llvm/lib/Support/regcomp.c:540
REQUIRE(!MORE() || !isdigit((uch)PEEK()), REG_BADRPT);
- /* FALLTHROUGH */
+ __attribute__((fallthrough));
default:
----------------
nickdesaulniers wrote:
> aaron.ballman wrote:
> > The macros in Compiler.h should be updated so that this can use `LLVM_FALLTHROUGH` instead to prevent compile errors.
> ah, right, otherwise we get into situations where older versions of clang (or other bootstrap compilers) that don't have this feature don't understand this attribute
Yes, as-is this would break everyone building Clang with MSVC (for instance).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66487/new/
https://reviews.llvm.org/D66487
More information about the llvm-commits
mailing list