diff options
author | Guillem Jover <guillem@hadrons.org> | 2011-05-25 21:27:12 +0200 |
---|---|---|
committer | Guillem Jover <guillem@hadrons.org> | 2011-05-28 10:31:07 +0200 |
commit | 87dd203c26f2828de9506da5a0073aa0f6593c9e (patch) | |
tree | 69c08741b96be1d9f1d43aca2c06ddb47ab7e661 | |
parent | de2062873f2b90bb8d09d213931ee1150ffd6b77 (diff) | |
download | libbsd-87dd203c26f2828de9506da5a0073aa0f6593c9e.tar.gz |
Define __dead2 and __pure2 to actual gcc attributes if possible
-rw-r--r-- | include/bsd/sys/cdefs.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/include/bsd/sys/cdefs.h b/include/bsd/sys/cdefs.h index 3c31b05..a1ea034 100644 --- a/include/bsd/sys/cdefs.h +++ b/include/bsd/sys/cdefs.h @@ -50,11 +50,19 @@ #endif #ifndef __dead2 -# define __dead2 +# if LIBBSD_GCC_VERSION >= 0x0207 +# define __dead2 __attribute__((__noreturn__)) +# else +# define __dead2 +# endif #endif #ifndef __pure2 -# define __pure2 +# if LIBBSD_GCC_VERSION >= 0x0207 +# define __pure2 __attribute__((__const__)) +# else +# define __pure2 +# endif #endif /* Linux headers define a struct with a member names __unused. |