diff options
author | Bruno Haible <bruno@clisp.org> | 2020-12-20 14:41:29 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2020-12-20 14:42:32 +0100 |
commit | e468da0cd12de75bdafafe295773ecda6551c21a (patch) | |
tree | ed40c72d39564bcef497c49cc5daa068ce0eb537 /lib | |
parent | 090c4cb9be5a44a9ec45a493ba3acda9f5161b6e (diff) | |
download | gnulib-e468da0cd12de75bdafafe295773ecda6551c21a.tar.gz |
float: Fix compilation error when gnulib's float.h exists twice.
Reported by Santiago Vila <sanvila@unex.es>.
* lib/float.in.h (GNULIB_defined_long_double_union): New macro.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/float.in.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/float.in.h b/lib/float.in.h index 8e4d47dc07..7988cc790d 100644 --- a/lib/float.in.h +++ b/lib/float.in.h @@ -93,11 +93,14 @@ extern const long double LDBL_MAX; Unfortunately, this is not a constant expression. */ +# if !GNULIB_defined_long_double_union union gl_long_double_union { struct { unsigned int lo; unsigned int hi; unsigned int exponent; } xd; long double ld; }; +# define GNULIB_defined_long_double_union 1 +# endif extern const union gl_long_double_union gl_LDBL_MAX; # define LDBL_MAX (gl_LDBL_MAX.ld) /* Minimum e such that 10^e is in the range of normalized numbers. */ |