diff options
Diffstat (limited to 'lib/macros.h')
-rw-r--r-- | lib/macros.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/lib/macros.h b/lib/macros.h index a61f80e..6369599 100644 --- a/lib/macros.h +++ b/lib/macros.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009-2015 Richard Braun. + * Copyright (c) 2009-2018 Richard Braun. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -91,4 +91,16 @@ #define __unused __attribute__((unused)) #endif +#ifndef __used +#define __used __attribute__((used)) +#endif + +#ifndef __fallthrough +#if __GNUC__ >= 7 +#define __fallthrough __attribute__((fallthrough)) +#else /* __GNUC__ >= 7 */ +#define __fallthrough +#endif /* __GNUC__ >= 7 */ +#endif + #endif /* _MACROS_H */ |