Skip to content

Commit 9002dc7

Browse files
committed
Use __GNUC__ macro to determine if __has_attribute is supported
1 parent fa8f373 commit 9002dc7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/common/tusb_compiler.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@
138138
#define TU_ATTR_BIT_FIELD_ORDER_BEGIN
139139
#define TU_ATTR_BIT_FIELD_ORDER_END
140140

141-
#if defined(__XC16)
141+
#if __GNUC__ < 5
142142
#define TU_ATTR_FALLTHROUGH do {} while (0) /* fallthrough */
143143
#else
144144
#if __has_attribute(__fallthrough__)

0 commit comments

Comments
 (0)