ceil, trunc, round: Fix gcc warnings.
authorBruno Haible <bruno@clisp.org>
Sat, 25 Dec 2010 01:58:27 +0000 (02:58 +0100)
committerBruno Haible <bruno@clisp.org>
Sat, 25 Dec 2010 01:58:27 +0000 (02:58 +0100)
* lib/ceil.c (MIN): Undefine before redefining.
* lib/trunc.c (MIN): Likewise.
* lib/round.c (MIN): Likewise.
Include <math.h> first.

ChangeLog
lib/ceil.c
lib/round.c
lib/trunc.c

index 6124d25e1b0e81820a2aa5616e76e4b90ce52dc9..be6b4317e1d38360f1154135f6956e597aedc1b8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2010-12-24  Bruno Haible  <bruno@clisp.org>
+
+       ceil, trunc, round: Fix gcc warnings.
+       * lib/ceil.c (MIN): Undefine before redefining.
+       * lib/trunc.c (MIN): Likewise.
+       * lib/round.c (MIN): Likewise.
+       Include <math.h> first.
+
 2010-12-24  Bruno Haible  <bruno@clisp.org>
 
        select tests: Avoid failures on OSF/1 5.1.
index 2ed16540ae802c349b39ec06cc4884a73c67d542..5882cad832972f952d24d2577c78de08e1b3fcaf 100644 (file)
@@ -23,6 +23,8 @@
 
 #include <float.h>
 
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define FUNC ceill
 # define DOUBLE long double
index 07ec4cdf8c2ee08087b27af8e8ba0d9517a28b46..df56266cd525faa3c3b1326d4b7ead5bbd09c886 100644 (file)
 
 #include <config.h>
 
-#include <float.h>
+/* Specification.  */
 #include <math.h>
 
+#include <float.h>
+
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define ROUND roundl
 # define FLOOR floorl
index 350459b2e3d418471cee5c126b0ee3959e036e0c..347d9ac21011dd2efcec565c51e61a29cdf77274 100644 (file)
@@ -23,6 +23,8 @@
 
 #include <float.h>
 
+#undef MIN
+
 #ifdef USE_LONG_DOUBLE
 # define FUNC truncl
 # define DOUBLE long double