reafactor noreturn macro
This commit is contained in:
parent
8625f75470
commit
0b7597b80b
|
@ -10,9 +10,11 @@ extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if __STDC_VERSION__ >= 201112L
|
#if __STDC_VERSION__ >= 201112L
|
||||||
# define noreturn _Noreturn
|
# include <stdnoreturn.h>
|
||||||
#elif __GNUC__ || __clang__
|
#elif __GNUC__ || __clang__
|
||||||
# define noreturn __attribute__((noreturn))
|
# define noreturn __attribute__((noreturn))
|
||||||
|
#else
|
||||||
|
# define noreturn
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define FALLTHROUGH ((void)0)
|
#define FALLTHROUGH ((void)0)
|
||||||
|
|
Loading…
Reference in New Issue