summaryrefslogtreecommitdiff
path: root/lib/compiler.h
diff options
context:
space:
mode:
authorDonald Sharp <donaldsharp72@gmail.com>2023-10-13 11:51:11 -0400
committerGitHub <noreply@github.com>2023-10-13 11:51:11 -0400
commit02cbd978011ca0a8afe729ac67f7c00009d5ca0d (patch)
treea43347ff1519213c9176d5ad5515ec3468f4eaad /lib/compiler.h
parent4fa73b6572df03fd9df7ffddf279abbcf8ad6b9c (diff)
parent7d67b9ff28d09de58c632f80ef7d330e45e698f6 (diff)
Merge pull request #14561 from idryzhov/implicit-fallthrough
build: add -Wimplicit-fallthrough
Diffstat (limited to 'lib/compiler.h')
-rw-r--r--lib/compiler.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/compiler.h b/lib/compiler.h
index ce6727685f..0a54c02d20 100644
--- a/lib/compiler.h
+++ b/lib/compiler.h
@@ -33,7 +33,7 @@ extern "C" {
# define _RET_NONNULL , returns_nonnull
#endif
#if __has_attribute(fallthrough)
-# define _FALLTHROUGH __attribute__((fallthrough));
+# define fallthrough __attribute__((fallthrough));
#endif
# define _CONSTRUCTOR(x) constructor(x)
# define _DEPRECATED(x) deprecated(x)
@@ -57,7 +57,7 @@ extern "C" {
# define __has_attribute(x) 0
#endif
#if __GNUC__ >= 7
-# define _FALLTHROUGH __attribute__((fallthrough));
+# define fallthrough __attribute__((fallthrough));
#endif
#endif
@@ -112,8 +112,8 @@ extern "C" {
#ifndef _ALLOC_SIZE
# define _ALLOC_SIZE(x)
#endif
-#ifndef _FALLTHROUGH
-#define _FALLTHROUGH
+#ifndef fallthrough
+#define fallthrough
#endif
#ifndef _DEPRECATED
#define _DEPRECATED(x) deprecated