mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
_Static_assert needs two arguments for compatibility with GCC before 9
This macro definition enforces two arguments even with newer compilers
that accept the single-argument form, too.
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
(cherry picked from commit c9fef4b7d1
)
This commit is contained in:
parent
405b8ae135
commit
a1c12fdf3f
@ -1,5 +1,12 @@
|
||||
#ifndef _SYS_CDEFS_H
|
||||
|
||||
/* This is outside of _ISOMAC to enforce that _Static_assert always
|
||||
uses the two-argument form. This can be removed once the minimum
|
||||
GCC version used to compile glibc is GCC 9.1. */
|
||||
#ifndef __cplusplus
|
||||
# define _Static_assert(expr, diagnostic) _Static_assert (expr, diagnostic)
|
||||
#endif
|
||||
|
||||
#include <misc/sys/cdefs.h>
|
||||
|
||||
#ifndef _ISOMAC
|
||||
|
Loading…
Reference in New Issue
Block a user