diff options
author | Gabriel F. T. Gomes <gftg@linux.vnet.ibm.com> | 2016-12-09 11:41:55 -0200 |
---|---|---|
committer | Gabriel F. T. Gomes <gftg@linux.vnet.ibm.com> | 2017-05-17 18:59:23 -0300 |
commit | 477bf19a590b6e6de65f326cb00dcb8999fa8b26 (patch) | |
tree | abb4d8a31bc1a82c783d021e2a7991b7e923c408 /misc/sys | |
parent | b2980e3c545294d71b3960ce74b6148e274d2488 (diff) | |
download | glibc-477bf19a590b6e6de65f326cb00dcb8999fa8b26.tar.gz glibc-477bf19a590b6e6de65f326cb00dcb8999fa8b26.tar.xz glibc-477bf19a590b6e6de65f326cb00dcb8999fa8b26.zip |
float128: Extend __MATH_TG for float128 support
* math/math.h (__MATH_TG): Extend the conditions to add _Float128 support. * misc/sys/cdefs.h (__HAVE_GENERIC_SELECTION): New macro.
Diffstat (limited to 'misc/sys')
-rw-r--r-- | misc/sys/cdefs.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/misc/sys/cdefs.h b/misc/sys/cdefs.h index 74f9a49b05..06523bfe9c 100644 --- a/misc/sys/cdefs.h +++ b/misc/sys/cdefs.h @@ -464,4 +464,20 @@ # define __glibc_macro_warning(msg) #endif +/* Support for generic selection (ISO C11) is available in GCC since + version 4.9. Previous versions do not provide generic selection, + even though they might set __STDC_VERSION__ to 201112L, when in + -std=c11 mode. Thus, we must check for !defined __GNUC__ when + testing __STDC_VERSION__ for generic selection support. + On the other hand, Clang also defines __GNUC__, so a clang-specific + check is required to enable the use of generic selection. */ +#if __GNUC_PREREQ (4, 9) \ + || __glibc_clang_has_extension (c_generic_selections) \ + || (!defined __GNUC__ && defined __STDC_VERSION__ \ + && __STDC_VERSION__ >= 201112L) +# define __HAVE_GENERIC_SELECTION 1 +#else +# define __HAVE_GENERIC_SELECTION 0 +#endif + #endif /* sys/cdefs.h */ |