diff options
Diffstat (limited to 'include/ansidecl.h')
-rw-r--r-- | include/ansidecl.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/ansidecl.h b/include/ansidecl.h index 2b5c0e7..9e8a457 100644 --- a/include/ansidecl.h +++ b/include/ansidecl.h @@ -187,6 +187,15 @@ So instead we use the macro below and test it against specific values. */ # define __attribute__(x) #endif +/* Attribute __malloc__ on functions was valid as of gcc 2.96. */ +#ifndef ATTRIBUTE_MALLOC +# if (GCC_VERSION >= 2096) +# define ATTRIBUTE_MALLOC __attribute__ ((__malloc__)) +# else +# define ATTRIBUTE_MALLOC +# endif /* GNUC >= 2.96 */ +#endif /* ATTRIBUTE_MALLOC */ + /* Attributes on labels were valid as of gcc 2.93. */ #ifndef ATTRIBUTE_UNUSED_LABEL # if (GCC_VERSION >= 2093) |