SIGN IN SIGN UP

gh-128902: Fix check for fallthrough attribute support (#128903)

Clang versions prior to 10 (which corresponds to Apple Clang 12) do not
support the GCC extension syntax __attribute__((fallthrough)), but do
evaluate __has_attribute(fallthrough) to 1 because they support the
C++11 style syntax [[fallthrough]]. The only way to tell if the GCC
style syntax is supported is thus to check the clang version.

Ref: https://github.com/llvm/llvm-project/commit/1e0affb6e564b7361b0aadb38805f26deff4ecfc
J
Joshua Root committed
edf803345a5c57c38fca3850386530e30b397eca
Parent: 86c1a60
Committed by GitHub <noreply@github.com> on 1/22/2025, 9:25:30 AM