Fix __size_alloc()
Use underscore for the attributes name: this should fix the use of the attributes in macros for lint(1). Suggested by: bde X-MFC with: r280700
This commit is contained in:
parent
fed2d5edfc
commit
2b092a1664
@ -212,7 +212,6 @@
|
||||
#define __unused
|
||||
#define __packed
|
||||
#define __aligned(x)
|
||||
#define __alloc_size(...)
|
||||
#define __section(x)
|
||||
#define __weak
|
||||
#else
|
||||
@ -237,11 +236,6 @@
|
||||
#define __aligned(x) __attribute__((__aligned__(x)))
|
||||
#define __section(x) __attribute__((__section__(x)))
|
||||
#endif
|
||||
#if __has_attribute(alloc_size) || __GNUC_PREREQ__(4, 3)
|
||||
#define __alloc_size(...) __attribute__((alloc_size(__VA_ARGS__)))
|
||||
#else
|
||||
#define __alloc_size(...)
|
||||
#endif
|
||||
#if defined(__INTEL_COMPILER)
|
||||
#define __dead2 __attribute__((__noreturn__))
|
||||
#define __pure2 __attribute__((__const__))
|
||||
@ -384,6 +378,12 @@
|
||||
#define __returns_twice
|
||||
#endif
|
||||
|
||||
#if __has_attribute(alloc_size) || __GNUC_PREREQ__(4, 3)
|
||||
#define __alloc_size(...) __attribute__((__alloc_size__(__VA_ARGS__)))
|
||||
#else
|
||||
#define __alloc_size(...)
|
||||
#endif
|
||||
|
||||
/* XXX: should use `#if __STDC_VERSION__ < 199901'. */
|
||||
#if !__GNUC_PREREQ__(2, 7) && !defined(__INTEL_COMPILER)
|
||||
#define __func__ NULL
|
||||
|
Loading…
x
Reference in New Issue
Block a user