]> Savannah Git Hosting - gnulib.git/commitdiff
ldexpl: Avoid possible -Wshadow warning.
authorBruno Haible <bruno@clisp.org>
Sat, 19 Aug 2023 23:44:26 +0000 (01:44 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 30 Aug 2023 10:16:26 +0000 (12:16 +0200)
* lib/ldexpl.c (exp): Locally rename to 'exponent'.

ChangeLog
lib/ldexpl.c

index 8ad2f8e5eb8c3179a314f217f99f6a2d0a4aab1a..f3535cc7d8cf1549f62192a50cf98c157c780d79 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2023-08-19  Bruno Haible  <bruno@clisp.org>
 
+       ldexpl: Avoid possible -Wshadow warning.
+       * lib/ldexpl.c (exp): Locally rename to 'exponent'.
+
        ldexpl: Fix signed integer overflow.
        * lib/ldexpl.c (ldexpl): Use an 'unsigned int' variable to represent the
        absolute value of exp without overflow.
index 51aed6f6d44ac508bb81cb6e12ced2e6f8880c4c..0cd7673d0b2984bc81c030515fdfb48855b8559d 100644 (file)
 /* Specification.  */
 #include <math.h>
 
+/* Avoid some warnings from "gcc -Wshadow".
+   This file doesn't use the exp() function.  */
+#undef exp
+#define exp exponent
+
 #if HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
 
 long double