diff options
author | Richard Braun <rbraun@sceen.net> | 2017-10-31 00:53:02 +0100 |
---|---|---|
committer | Richard Braun <rbraun@sceen.net> | 2017-10-31 00:53:02 +0100 |
commit | 3aa27e426b61b92cdb0e5b5503dd12ece85b4d69 (patch) | |
tree | 545c6ce2ff6c0d6ec795cd87a7d0fd623504c28b /kern/macros.h | |
parent | 3fc6079789f3a6c4b7fdb885bac7da2ffde11634 (diff) | |
parent | b5c668a0b8fdc6e9c3b60765b1a7f321916b49c8 (diff) |
Merge branch 'master' into arm_port_dev
Diffstat (limited to 'kern/macros.h')
-rw-r--r-- | kern/macros.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/kern/macros.h b/kern/macros.h index d09eca40..23ad4d22 100644 --- a/kern/macros.h +++ b/kern/macros.h @@ -106,4 +106,13 @@ moo_print(const char *s) #define __used __attribute__((used)) #endif +#ifndef __fallthrough +#if __GNUC__ >= 7 +#define __fallthrough __attribute__((fallthrough)) +#else +/* TODO: clang 6 might add support for -Wimplicit-fallthrough */ +#define __fallthrough +#endif +#endif + #endif /* _KERN_MACROS_H */ |