math: Sort function declarations of math.in.h.
authorBruno Haible <bruno@clisp.org>
Thu, 6 Oct 2011 08:56:19 +0000 (10:56 +0200)
committerBruno Haible <bruno@clisp.org>
Thu, 6 Oct 2011 08:56:19 +0000 (10:56 +0200)
* lib/math.in.h (frexp, logb): Move declarations.

ChangeLog
lib/math.in.h

index 25753ac..6dd6ac8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-10-06  Bruno Haible  <bruno@clisp.org>
+
+       math: Sort function declarations of math.in.h.
+       * lib/math.in.h (frexp, logb): Move declarations.
+
 2011-10-05  Bruno Haible  <bruno@clisp.org>
 
        Tests for module 'modff'.
index 435d79c..80bc78c 100644 (file)
@@ -108,45 +108,6 @@ _NaN ()
 #endif
 
 
-/* Write x as
-     x = mantissa * 2^exp
-   where
-     If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
-     If x is zero: mantissa = x, exp = 0.
-     If x is infinite or NaN: mantissa = x, exp unspecified.
-   Store exp in *EXPPTR and return mantissa.  */
-#if @GNULIB_FREXP@
-# if @REPLACE_FREXP@
-#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
-#   define frexp rpl_frexp
-#  endif
-_GL_FUNCDECL_RPL (frexp, double, (double x, int *expptr) _GL_ARG_NONNULL ((2)));
-_GL_CXXALIAS_RPL (frexp, double, (double x, int *expptr));
-# else
-_GL_CXXALIAS_SYS (frexp, double, (double x, int *expptr));
-# endif
-_GL_CXXALIASWARN (frexp);
-#elif defined GNULIB_POSIXCHECK
-# undef frexp
-/* Assume frexp is always declared.  */
-_GL_WARN_ON_USE (frexp, "frexp is unportable - "
-                 "use gnulib module frexp for portability");
-#endif
-
-
-#if @GNULIB_LOGB@
-# if !@HAVE_DECL_LOGB@
-_GL_EXTERN_C double logb (double x);
-# endif
-#elif defined GNULIB_POSIXCHECK
-# undef logb
-# if HAVE_RAW_DECL_LOGB
-_GL_WARN_ON_USE (logb, "logb is unportable - "
-                 "use gnulib module logb for portability");
-# endif
-#endif
-
-
 #if @GNULIB_ACOSL@
 # if !@HAVE_ACOSL@ || !@HAVE_DECL_ACOSL@
 _GL_FUNCDECL_SYS (acosl, long double, (long double x));
@@ -381,6 +342,31 @@ _GL_WARN_ON_USE (fmodf, "fmodf is unportable - "
      If x is zero: mantissa = x, exp = 0.
      If x is infinite or NaN: mantissa = x, exp unspecified.
    Store exp in *EXPPTR and return mantissa.  */
+#if @GNULIB_FREXP@
+# if @REPLACE_FREXP@
+#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
+#   define frexp rpl_frexp
+#  endif
+_GL_FUNCDECL_RPL (frexp, double, (double x, int *expptr) _GL_ARG_NONNULL ((2)));
+_GL_CXXALIAS_RPL (frexp, double, (double x, int *expptr));
+# else
+_GL_CXXALIAS_SYS (frexp, double, (double x, int *expptr));
+# endif
+_GL_CXXALIASWARN (frexp);
+#elif defined GNULIB_POSIXCHECK
+# undef frexp
+/* Assume frexp is always declared.  */
+_GL_WARN_ON_USE (frexp, "frexp is unportable - "
+                 "use gnulib module frexp for portability");
+#endif
+
+/* Write x as
+     x = mantissa * 2^exp
+   where
+     If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
+     If x is zero: mantissa = x, exp = 0.
+     If x is infinite or NaN: mantissa = x, exp unspecified.
+   Store exp in *EXPPTR and return mantissa.  */
 #if @GNULIB_FREXPL@ && @REPLACE_FREXPL@
 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 #  undef frexpl
@@ -438,6 +424,19 @@ _GL_WARN_ON_USE (ldexpl, "ldexpl is unportable - "
 #endif
 
 
+#if @GNULIB_LOGB@
+# if !@HAVE_DECL_LOGB@
+_GL_EXTERN_C double logb (double x);
+# endif
+#elif defined GNULIB_POSIXCHECK
+# undef logb
+# if HAVE_RAW_DECL_LOGB
+_GL_WARN_ON_USE (logb, "logb is unportable - "
+                 "use gnulib module logb for portability");
+# endif
+#endif
+
+
 #if @GNULIB_LOGL@
 # if !@HAVE_LOGL@ || !@HAVE_DECL_LOGL@
 _GL_FUNCDECL_SYS (logl, long double, (long double x));
@@ -652,6 +651,10 @@ _GL_WARN_ON_USE (truncl, "truncl is unportable - "
 #endif
 
 
+/* Definitions of function-like macros come here, after the function
+   declarations.  */
+
+
 #if @GNULIB_ISFINITE@
 # if @REPLACE_ISFINITE@
 _GL_EXTERN_C int gl_isfinitef (float x);