Skip to content

Commit ee47b2b

Browse files
committed
Exclude NetBSD from Clang fallthrough attribute in _Py_FALLTHROUGH macro
1 parent 05e89c3 commit ee47b2b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Include/pyport.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -630,7 +630,7 @@ extern "C" {
630630
// style fallthrough attribute, not the GCC extension syntax used here,
631631
// and __has_attribute(fallthrough) evaluates to 1.
632632
#if _Py__has_attribute(fallthrough) && (!defined(__clang__) || \
633-
(!defined(__apple_build_version__) && __clang_major__ >= 10) || \
633+
((!defined(__apple_build_version__) && !defined(__NetBSD__)) && __clang_major__ >= 10) || \
634634
(defined(__apple_build_version__) && __clang_major__ >= 12))
635635
# define _Py_FALLTHROUGH __attribute__((fallthrough))
636636
#else

0 commit comments

Comments
 (0)