about summary refs log tree commit diff
path: root/misc
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2019-06-14 15:46:02 +0200
committerFlorian Weimer <fweimer@redhat.com>2019-06-14 16:19:14 +0200
commit8d141877e07cc594e9fefc3795b8ba729288093c (patch)
tree096e8ccbb3d17636b03bc41afa28e5a3e89e1d64 /misc
parentcf274686024128f9fd75d4878211a018b2cfa5ac (diff)
downloadglibc-8d141877e07cc594e9fefc3795b8ba729288093c.tar.gz
glibc-8d141877e07cc594e9fefc3795b8ba729288093c.tar.xz
glibc-8d141877e07cc594e9fefc3795b8ba729288093c.zip
<sys/cdefs.h>: Inhibit macro expansion for __glibc_has_include
This is currently ineffective with GCC because of GCC PR 80005, but
it makes sense to anticipate a fix for this defect.

Suggested by Zack Weinberg.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Diffstat (limited to 'misc')
-rw-r--r--misc/sys/cdefs.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/misc/sys/cdefs.h b/misc/sys/cdefs.h
index 638872b87b..f1bd994a10 100644
--- a/misc/sys/cdefs.h
+++ b/misc/sys/cdefs.h
@@ -413,7 +413,9 @@
 #endif
 
 #ifdef __has_include
-# define __glibc_has_include(header)	__has_include (header)
+/* Do not use a function-like macro, so that __has_include can inhibit
+   macro expansion.  */
+# define __glibc_has_include __has_include
 #else
 # define __glibc_has_include(header)	0
 #endif