diff --git a/include/sys/cdefs.h b/include/sys/cdefs.h index 6a76160ed4..56adb231aa 100644 --- a/include/sys/cdefs.h +++ b/include/sys/cdefs.h @@ -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 #ifndef _ISOMAC