1*fd82c4c4Schristos /* This file is automatically generated.  DO NOT EDIT! */
2*fd82c4c4Schristos /* Generated from: NetBSD: mknative-gdb,v 1.12 2020/09/17 16:54:31 christos Exp  */
3*fd82c4c4Schristos /* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp  */
4*fd82c4c4Schristos 
5*fd82c4c4Schristos /* DO NOT EDIT! GENERATED AUTOMATICALLY! */
6*fd82c4c4Schristos /* A GNU-like <math.h>.
7*fd82c4c4Schristos 
8*fd82c4c4Schristos    Copyright (C) 2002-2003, 2007-2020 Free Software Foundation, Inc.
9*fd82c4c4Schristos 
10*fd82c4c4Schristos    This program is free software: you can redistribute it and/or modify
11*fd82c4c4Schristos    it under the terms of the GNU General Public License as published by
12*fd82c4c4Schristos    the Free Software Foundation; either version 3 of the License, or
13*fd82c4c4Schristos    (at your option) any later version.
14*fd82c4c4Schristos 
15*fd82c4c4Schristos    This program is distributed in the hope that it will be useful,
16*fd82c4c4Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
17*fd82c4c4Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18*fd82c4c4Schristos    GNU General Public License for more details.
19*fd82c4c4Schristos 
20*fd82c4c4Schristos    You should have received a copy of the GNU General Public License
21*fd82c4c4Schristos    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
22*fd82c4c4Schristos 
23*fd82c4c4Schristos #ifndef _GL_MATH_H
24*fd82c4c4Schristos 
25*fd82c4c4Schristos #if __GNUC__ >= 3
26*fd82c4c4Schristos #pragma GCC system_header
27*fd82c4c4Schristos #endif
28*fd82c4c4Schristos 
29*fd82c4c4Schristos 
30*fd82c4c4Schristos /* The include_next requires a split double-inclusion guard.  */
31*fd82c4c4Schristos #include_next <math.h>
32*fd82c4c4Schristos 
33*fd82c4c4Schristos #ifndef _GL_MATH_H
34*fd82c4c4Schristos #define _GL_MATH_H
35*fd82c4c4Schristos 
36*fd82c4c4Schristos /* On OpenVMS, NAN, INFINITY, and HUGEVAL macros are defined in <fp.h>.  */
37*fd82c4c4Schristos #if defined __VMS && ! defined NAN
38*fd82c4c4Schristos # include <fp.h>
39*fd82c4c4Schristos #endif
40*fd82c4c4Schristos 
41*fd82c4c4Schristos #ifndef _GL_INLINE_HEADER_BEGIN
42*fd82c4c4Schristos  #error "Please include config.h first."
43*fd82c4c4Schristos #endif
44*fd82c4c4Schristos _GL_INLINE_HEADER_BEGIN
45*fd82c4c4Schristos #ifndef _GL_MATH_INLINE
46*fd82c4c4Schristos # define _GL_MATH_INLINE _GL_INLINE
47*fd82c4c4Schristos #endif
48*fd82c4c4Schristos 
49*fd82c4c4Schristos /* The definitions of _GL_FUNCDECL_RPL etc. are copied here.  */
50*fd82c4c4Schristos /* C++ compatible function declaration macros.
51*fd82c4c4Schristos    Copyright (C) 2010-2020 Free Software Foundation, Inc.
52*fd82c4c4Schristos 
53*fd82c4c4Schristos    This program is free software: you can redistribute it and/or modify it
54*fd82c4c4Schristos    under the terms of the GNU General Public License as published
55*fd82c4c4Schristos    by the Free Software Foundation; either version 3 of the License, or
56*fd82c4c4Schristos    (at your option) any later version.
57*fd82c4c4Schristos 
58*fd82c4c4Schristos    This program is distributed in the hope that it will be useful,
59*fd82c4c4Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
60*fd82c4c4Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
61*fd82c4c4Schristos    General Public License for more details.
62*fd82c4c4Schristos 
63*fd82c4c4Schristos    You should have received a copy of the GNU General Public License
64*fd82c4c4Schristos    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
65*fd82c4c4Schristos 
66*fd82c4c4Schristos #ifndef _GL_CXXDEFS_H
67*fd82c4c4Schristos #define _GL_CXXDEFS_H
68*fd82c4c4Schristos 
69*fd82c4c4Schristos /* Begin/end the GNULIB_NAMESPACE namespace.  */
70*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
71*fd82c4c4Schristos # define _GL_BEGIN_NAMESPACE namespace GNULIB_NAMESPACE {
72*fd82c4c4Schristos # define _GL_END_NAMESPACE }
73*fd82c4c4Schristos #else
74*fd82c4c4Schristos # define _GL_BEGIN_NAMESPACE
75*fd82c4c4Schristos # define _GL_END_NAMESPACE
76*fd82c4c4Schristos #endif
77*fd82c4c4Schristos 
78*fd82c4c4Schristos /* The three most frequent use cases of these macros are:
79*fd82c4c4Schristos 
80*fd82c4c4Schristos    * For providing a substitute for a function that is missing on some
81*fd82c4c4Schristos      platforms, but is declared and works fine on the platforms on which
82*fd82c4c4Schristos      it exists:
83*fd82c4c4Schristos 
84*fd82c4c4Schristos        #if @GNULIB_FOO@
85*fd82c4c4Schristos        # if !@HAVE_FOO@
86*fd82c4c4Schristos        _GL_FUNCDECL_SYS (foo, ...);
87*fd82c4c4Schristos        # endif
88*fd82c4c4Schristos        _GL_CXXALIAS_SYS (foo, ...);
89*fd82c4c4Schristos        _GL_CXXALIASWARN (foo);
90*fd82c4c4Schristos        #elif defined GNULIB_POSIXCHECK
91*fd82c4c4Schristos        ...
92*fd82c4c4Schristos        #endif
93*fd82c4c4Schristos 
94*fd82c4c4Schristos    * For providing a replacement for a function that exists on all platforms,
95*fd82c4c4Schristos      but is broken/insufficient and needs to be replaced on some platforms:
96*fd82c4c4Schristos 
97*fd82c4c4Schristos        #if @GNULIB_FOO@
98*fd82c4c4Schristos        # if @REPLACE_FOO@
99*fd82c4c4Schristos        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
100*fd82c4c4Schristos        #   undef foo
101*fd82c4c4Schristos        #   define foo rpl_foo
102*fd82c4c4Schristos        #  endif
103*fd82c4c4Schristos        _GL_FUNCDECL_RPL (foo, ...);
104*fd82c4c4Schristos        _GL_CXXALIAS_RPL (foo, ...);
105*fd82c4c4Schristos        # else
106*fd82c4c4Schristos        _GL_CXXALIAS_SYS (foo, ...);
107*fd82c4c4Schristos        # endif
108*fd82c4c4Schristos        _GL_CXXALIASWARN (foo);
109*fd82c4c4Schristos        #elif defined GNULIB_POSIXCHECK
110*fd82c4c4Schristos        ...
111*fd82c4c4Schristos        #endif
112*fd82c4c4Schristos 
113*fd82c4c4Schristos    * For providing a replacement for a function that exists on some platforms
114*fd82c4c4Schristos      but is broken/insufficient and needs to be replaced on some of them and
115*fd82c4c4Schristos      is additionally either missing or undeclared on some other platforms:
116*fd82c4c4Schristos 
117*fd82c4c4Schristos        #if @GNULIB_FOO@
118*fd82c4c4Schristos        # if @REPLACE_FOO@
119*fd82c4c4Schristos        #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
120*fd82c4c4Schristos        #   undef foo
121*fd82c4c4Schristos        #   define foo rpl_foo
122*fd82c4c4Schristos        #  endif
123*fd82c4c4Schristos        _GL_FUNCDECL_RPL (foo, ...);
124*fd82c4c4Schristos        _GL_CXXALIAS_RPL (foo, ...);
125*fd82c4c4Schristos        # else
126*fd82c4c4Schristos        #  if !@HAVE_FOO@   or   if !@HAVE_DECL_FOO@
127*fd82c4c4Schristos        _GL_FUNCDECL_SYS (foo, ...);
128*fd82c4c4Schristos        #  endif
129*fd82c4c4Schristos        _GL_CXXALIAS_SYS (foo, ...);
130*fd82c4c4Schristos        # endif
131*fd82c4c4Schristos        _GL_CXXALIASWARN (foo);
132*fd82c4c4Schristos        #elif defined GNULIB_POSIXCHECK
133*fd82c4c4Schristos        ...
134*fd82c4c4Schristos        #endif
135*fd82c4c4Schristos */
136*fd82c4c4Schristos 
137*fd82c4c4Schristos /* _GL_EXTERN_C declaration;
138*fd82c4c4Schristos    performs the declaration with C linkage.  */
139*fd82c4c4Schristos #if defined __cplusplus
140*fd82c4c4Schristos # define _GL_EXTERN_C extern "C"
141*fd82c4c4Schristos #else
142*fd82c4c4Schristos # define _GL_EXTERN_C extern
143*fd82c4c4Schristos #endif
144*fd82c4c4Schristos 
145*fd82c4c4Schristos /* _GL_FUNCDECL_RPL (func, rettype, parameters_and_attributes);
146*fd82c4c4Schristos    declares a replacement function, named rpl_func, with the given prototype,
147*fd82c4c4Schristos    consisting of return type, parameters, and attributes.
148*fd82c4c4Schristos    Example:
149*fd82c4c4Schristos      _GL_FUNCDECL_RPL (open, int, (const char *filename, int flags, ...)
150*fd82c4c4Schristos                                   _GL_ARG_NONNULL ((1)));
151*fd82c4c4Schristos  */
152*fd82c4c4Schristos #define _GL_FUNCDECL_RPL(func,rettype,parameters_and_attributes) \
153*fd82c4c4Schristos   _GL_FUNCDECL_RPL_1 (rpl_##func, rettype, parameters_and_attributes)
154*fd82c4c4Schristos #define _GL_FUNCDECL_RPL_1(rpl_func,rettype,parameters_and_attributes) \
155*fd82c4c4Schristos   _GL_EXTERN_C rettype rpl_func parameters_and_attributes
156*fd82c4c4Schristos 
157*fd82c4c4Schristos /* _GL_FUNCDECL_SYS (func, rettype, parameters_and_attributes);
158*fd82c4c4Schristos    declares the system function, named func, with the given prototype,
159*fd82c4c4Schristos    consisting of return type, parameters, and attributes.
160*fd82c4c4Schristos    Example:
161*fd82c4c4Schristos      _GL_FUNCDECL_SYS (open, int, (const char *filename, int flags, ...)
162*fd82c4c4Schristos                                   _GL_ARG_NONNULL ((1)));
163*fd82c4c4Schristos  */
164*fd82c4c4Schristos #define _GL_FUNCDECL_SYS(func,rettype,parameters_and_attributes) \
165*fd82c4c4Schristos   _GL_EXTERN_C rettype func parameters_and_attributes
166*fd82c4c4Schristos 
167*fd82c4c4Schristos /* _GL_CXXALIAS_RPL (func, rettype, parameters);
168*fd82c4c4Schristos    declares a C++ alias called GNULIB_NAMESPACE::func
169*fd82c4c4Schristos    that redirects to rpl_func, if GNULIB_NAMESPACE is defined.
170*fd82c4c4Schristos    Example:
171*fd82c4c4Schristos      _GL_CXXALIAS_RPL (open, int, (const char *filename, int flags, ...));
172*fd82c4c4Schristos 
173*fd82c4c4Schristos    Wrapping rpl_func in an object with an inline conversion operator
174*fd82c4c4Schristos    avoids a reference to rpl_func unless GNULIB_NAMESPACE::func is
175*fd82c4c4Schristos    actually used in the program.  */
176*fd82c4c4Schristos #define _GL_CXXALIAS_RPL(func,rettype,parameters) \
177*fd82c4c4Schristos   _GL_CXXALIAS_RPL_1 (func, rpl_##func, rettype, parameters)
178*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
179*fd82c4c4Schristos # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
180*fd82c4c4Schristos     namespace GNULIB_NAMESPACE                                \
181*fd82c4c4Schristos     {                                                         \
182*fd82c4c4Schristos       static const struct _gl_ ## func ## _wrapper            \
183*fd82c4c4Schristos       {                                                       \
184*fd82c4c4Schristos         typedef rettype (*type) parameters;                   \
185*fd82c4c4Schristos                                                               \
186*fd82c4c4Schristos         inline operator type () const                         \
187*fd82c4c4Schristos         {                                                     \
188*fd82c4c4Schristos           return ::rpl_func;                                  \
189*fd82c4c4Schristos         }                                                     \
190*fd82c4c4Schristos       } func = {};                                            \
191*fd82c4c4Schristos     }                                                         \
192*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
193*fd82c4c4Schristos #else
194*fd82c4c4Schristos # define _GL_CXXALIAS_RPL_1(func,rpl_func,rettype,parameters) \
195*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
196*fd82c4c4Schristos #endif
197*fd82c4c4Schristos 
198*fd82c4c4Schristos /* _GL_CXXALIAS_RPL_CAST_1 (func, rpl_func, rettype, parameters);
199*fd82c4c4Schristos    is like  _GL_CXXALIAS_RPL_1 (func, rpl_func, rettype, parameters);
200*fd82c4c4Schristos    except that the C function rpl_func may have a slightly different
201*fd82c4c4Schristos    declaration.  A cast is used to silence the "invalid conversion" error
202*fd82c4c4Schristos    that would otherwise occur.  */
203*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
204*fd82c4c4Schristos # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
205*fd82c4c4Schristos     namespace GNULIB_NAMESPACE                                     \
206*fd82c4c4Schristos     {                                                              \
207*fd82c4c4Schristos       static const struct _gl_ ## func ## _wrapper                 \
208*fd82c4c4Schristos       {                                                            \
209*fd82c4c4Schristos         typedef rettype (*type) parameters;                        \
210*fd82c4c4Schristos                                                                    \
211*fd82c4c4Schristos         inline operator type () const                              \
212*fd82c4c4Schristos         {                                                          \
213*fd82c4c4Schristos           return reinterpret_cast<type>(::rpl_func);               \
214*fd82c4c4Schristos         }                                                          \
215*fd82c4c4Schristos       } func = {};                                                 \
216*fd82c4c4Schristos     }                                                              \
217*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
218*fd82c4c4Schristos #else
219*fd82c4c4Schristos # define _GL_CXXALIAS_RPL_CAST_1(func,rpl_func,rettype,parameters) \
220*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
221*fd82c4c4Schristos #endif
222*fd82c4c4Schristos 
223*fd82c4c4Schristos /* _GL_CXXALIAS_SYS (func, rettype, parameters);
224*fd82c4c4Schristos    declares a C++ alias called GNULIB_NAMESPACE::func
225*fd82c4c4Schristos    that redirects to the system provided function func, if GNULIB_NAMESPACE
226*fd82c4c4Schristos    is defined.
227*fd82c4c4Schristos    Example:
228*fd82c4c4Schristos      _GL_CXXALIAS_SYS (open, int, (const char *filename, int flags, ...));
229*fd82c4c4Schristos 
230*fd82c4c4Schristos    Wrapping func in an object with an inline conversion operator
231*fd82c4c4Schristos    avoids a reference to func unless GNULIB_NAMESPACE::func is
232*fd82c4c4Schristos    actually used in the program.  */
233*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
234*fd82c4c4Schristos # define _GL_CXXALIAS_SYS(func,rettype,parameters)            \
235*fd82c4c4Schristos     namespace GNULIB_NAMESPACE                                \
236*fd82c4c4Schristos     {                                                         \
237*fd82c4c4Schristos       static const struct _gl_ ## func ## _wrapper            \
238*fd82c4c4Schristos       {                                                       \
239*fd82c4c4Schristos         typedef rettype (*type) parameters;                   \
240*fd82c4c4Schristos                                                               \
241*fd82c4c4Schristos         inline operator type () const                         \
242*fd82c4c4Schristos         {                                                     \
243*fd82c4c4Schristos           return ::func;                                      \
244*fd82c4c4Schristos         }                                                     \
245*fd82c4c4Schristos       } func = {};                                            \
246*fd82c4c4Schristos     }                                                         \
247*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
248*fd82c4c4Schristos #else
249*fd82c4c4Schristos # define _GL_CXXALIAS_SYS(func,rettype,parameters) \
250*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
251*fd82c4c4Schristos #endif
252*fd82c4c4Schristos 
253*fd82c4c4Schristos /* _GL_CXXALIAS_SYS_CAST (func, rettype, parameters);
254*fd82c4c4Schristos    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
255*fd82c4c4Schristos    except that the C function func may have a slightly different declaration.
256*fd82c4c4Schristos    A cast is used to silence the "invalid conversion" error that would
257*fd82c4c4Schristos    otherwise occur.  */
258*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
259*fd82c4c4Schristos # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
260*fd82c4c4Schristos     namespace GNULIB_NAMESPACE                          \
261*fd82c4c4Schristos     {                                                   \
262*fd82c4c4Schristos       static const struct _gl_ ## func ## _wrapper      \
263*fd82c4c4Schristos       {                                                 \
264*fd82c4c4Schristos         typedef rettype (*type) parameters;             \
265*fd82c4c4Schristos                                                         \
266*fd82c4c4Schristos         inline operator type () const                   \
267*fd82c4c4Schristos         {                                               \
268*fd82c4c4Schristos           return reinterpret_cast<type>(::func);        \
269*fd82c4c4Schristos         }                                               \
270*fd82c4c4Schristos       } func = {};                                      \
271*fd82c4c4Schristos     }                                                   \
272*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
273*fd82c4c4Schristos #else
274*fd82c4c4Schristos # define _GL_CXXALIAS_SYS_CAST(func,rettype,parameters) \
275*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
276*fd82c4c4Schristos #endif
277*fd82c4c4Schristos 
278*fd82c4c4Schristos /* _GL_CXXALIAS_SYS_CAST2 (func, rettype, parameters, rettype2, parameters2);
279*fd82c4c4Schristos    is like  _GL_CXXALIAS_SYS (func, rettype, parameters);
280*fd82c4c4Schristos    except that the C function is picked among a set of overloaded functions,
281*fd82c4c4Schristos    namely the one with rettype2 and parameters2.  Two consecutive casts
282*fd82c4c4Schristos    are used to silence the "cannot find a match" and "invalid conversion"
283*fd82c4c4Schristos    errors that would otherwise occur.  */
284*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
285*fd82c4c4Schristos   /* The outer cast must be a reinterpret_cast.
286*fd82c4c4Schristos      The inner cast: When the function is defined as a set of overloaded
287*fd82c4c4Schristos      functions, it works as a static_cast<>, choosing the designated variant.
288*fd82c4c4Schristos      When the function is defined as a single variant, it works as a
289*fd82c4c4Schristos      reinterpret_cast<>. The parenthesized cast syntax works both ways.  */
290*fd82c4c4Schristos # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
291*fd82c4c4Schristos     namespace GNULIB_NAMESPACE                                                \
292*fd82c4c4Schristos     {                                                                         \
293*fd82c4c4Schristos       static const struct _gl_ ## func ## _wrapper                            \
294*fd82c4c4Schristos       {                                                                       \
295*fd82c4c4Schristos         typedef rettype (*type) parameters;                                   \
296*fd82c4c4Schristos                                                                               \
297*fd82c4c4Schristos         inline operator type () const                                         \
298*fd82c4c4Schristos         {                                                                     \
299*fd82c4c4Schristos           return reinterpret_cast<type>((rettype2 (*) parameters2)(::func));  \
300*fd82c4c4Schristos         }                                                                     \
301*fd82c4c4Schristos       } func = {};                                                            \
302*fd82c4c4Schristos     }                                                                         \
303*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
304*fd82c4c4Schristos #else
305*fd82c4c4Schristos # define _GL_CXXALIAS_SYS_CAST2(func,rettype,parameters,rettype2,parameters2) \
306*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
307*fd82c4c4Schristos #endif
308*fd82c4c4Schristos 
309*fd82c4c4Schristos /* _GL_CXXALIASWARN (func);
310*fd82c4c4Schristos    causes a warning to be emitted when ::func is used but not when
311*fd82c4c4Schristos    GNULIB_NAMESPACE::func is used.  func must be defined without overloaded
312*fd82c4c4Schristos    variants.  */
313*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
314*fd82c4c4Schristos # define _GL_CXXALIASWARN(func) \
315*fd82c4c4Schristos    _GL_CXXALIASWARN_1 (func, GNULIB_NAMESPACE)
316*fd82c4c4Schristos # define _GL_CXXALIASWARN_1(func,namespace) \
317*fd82c4c4Schristos    _GL_CXXALIASWARN_2 (func, namespace)
318*fd82c4c4Schristos /* To work around GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
319*fd82c4c4Schristos    we enable the warning only when not optimizing.  */
320*fd82c4c4Schristos # if !__OPTIMIZE__
321*fd82c4c4Schristos #  define _GL_CXXALIASWARN_2(func,namespace) \
322*fd82c4c4Schristos     _GL_WARN_ON_USE (func, \
323*fd82c4c4Schristos                      "The symbol ::" #func " refers to the system function. " \
324*fd82c4c4Schristos                      "Use " #namespace "::" #func " instead.")
325*fd82c4c4Schristos # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
326*fd82c4c4Schristos #  define _GL_CXXALIASWARN_2(func,namespace) \
327*fd82c4c4Schristos      extern __typeof__ (func) func
328*fd82c4c4Schristos # else
329*fd82c4c4Schristos #  define _GL_CXXALIASWARN_2(func,namespace) \
330*fd82c4c4Schristos      _GL_EXTERN_C int _gl_cxxalias_dummy
331*fd82c4c4Schristos # endif
332*fd82c4c4Schristos #else
333*fd82c4c4Schristos # define _GL_CXXALIASWARN(func) \
334*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
335*fd82c4c4Schristos #endif
336*fd82c4c4Schristos 
337*fd82c4c4Schristos /* _GL_CXXALIASWARN1 (func, rettype, parameters_and_attributes);
338*fd82c4c4Schristos    causes a warning to be emitted when the given overloaded variant of ::func
339*fd82c4c4Schristos    is used but not when GNULIB_NAMESPACE::func is used.  */
340*fd82c4c4Schristos #if defined __cplusplus && defined GNULIB_NAMESPACE
341*fd82c4c4Schristos # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
342*fd82c4c4Schristos    _GL_CXXALIASWARN1_1 (func, rettype, parameters_and_attributes, \
343*fd82c4c4Schristos                         GNULIB_NAMESPACE)
344*fd82c4c4Schristos # define _GL_CXXALIASWARN1_1(func,rettype,parameters_and_attributes,namespace) \
345*fd82c4c4Schristos    _GL_CXXALIASWARN1_2 (func, rettype, parameters_and_attributes, namespace)
346*fd82c4c4Schristos /* To work around GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881>,
347*fd82c4c4Schristos    we enable the warning only when not optimizing.  */
348*fd82c4c4Schristos # if !__OPTIMIZE__
349*fd82c4c4Schristos #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
350*fd82c4c4Schristos     _GL_WARN_ON_USE_CXX (func, rettype, parameters_and_attributes, \
351*fd82c4c4Schristos                          "The symbol ::" #func " refers to the system function. " \
352*fd82c4c4Schristos                          "Use " #namespace "::" #func " instead.")
353*fd82c4c4Schristos # else
354*fd82c4c4Schristos #  define _GL_CXXALIASWARN1_2(func,rettype,parameters_and_attributes,namespace) \
355*fd82c4c4Schristos      _GL_EXTERN_C int _gl_cxxalias_dummy
356*fd82c4c4Schristos # endif
357*fd82c4c4Schristos #else
358*fd82c4c4Schristos # define _GL_CXXALIASWARN1(func,rettype,parameters_and_attributes) \
359*fd82c4c4Schristos     _GL_EXTERN_C int _gl_cxxalias_dummy
360*fd82c4c4Schristos #endif
361*fd82c4c4Schristos 
362*fd82c4c4Schristos #endif /* _GL_CXXDEFS_H */
363*fd82c4c4Schristos 
364*fd82c4c4Schristos /* The definition of _GL_ARG_NONNULL is copied here.  */
365*fd82c4c4Schristos /* A C macro for declaring that specific arguments must not be NULL.
366*fd82c4c4Schristos    Copyright (C) 2009-2020 Free Software Foundation, Inc.
367*fd82c4c4Schristos 
368*fd82c4c4Schristos    This program is free software: you can redistribute it and/or modify it
369*fd82c4c4Schristos    under the terms of the GNU General Public License as published
370*fd82c4c4Schristos    by the Free Software Foundation; either version 3 of the License, or
371*fd82c4c4Schristos    (at your option) any later version.
372*fd82c4c4Schristos 
373*fd82c4c4Schristos    This program is distributed in the hope that it will be useful,
374*fd82c4c4Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
375*fd82c4c4Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
376*fd82c4c4Schristos    General Public License for more details.
377*fd82c4c4Schristos 
378*fd82c4c4Schristos    You should have received a copy of the GNU General Public License
379*fd82c4c4Schristos    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
380*fd82c4c4Schristos 
381*fd82c4c4Schristos /* _GL_ARG_NONNULL((n,...,m)) tells the compiler and static analyzer tools
382*fd82c4c4Schristos    that the values passed as arguments n, ..., m must be non-NULL pointers.
383*fd82c4c4Schristos    n = 1 stands for the first argument, n = 2 for the second argument etc.  */
384*fd82c4c4Schristos #ifndef _GL_ARG_NONNULL
385*fd82c4c4Schristos # if (__GNUC__ == 3 && __GNUC_MINOR__ >= 3) || __GNUC__ > 3
386*fd82c4c4Schristos #  define _GL_ARG_NONNULL(params) __attribute__ ((__nonnull__ params))
387*fd82c4c4Schristos # else
388*fd82c4c4Schristos #  define _GL_ARG_NONNULL(params)
389*fd82c4c4Schristos # endif
390*fd82c4c4Schristos #endif
391*fd82c4c4Schristos 
392*fd82c4c4Schristos /* The definition of _GL_WARN_ON_USE is copied here.  */
393*fd82c4c4Schristos /* A C macro for emitting warnings if a function is used.
394*fd82c4c4Schristos    Copyright (C) 2010-2020 Free Software Foundation, Inc.
395*fd82c4c4Schristos 
396*fd82c4c4Schristos    This program is free software: you can redistribute it and/or modify it
397*fd82c4c4Schristos    under the terms of the GNU General Public License as published
398*fd82c4c4Schristos    by the Free Software Foundation; either version 3 of the License, or
399*fd82c4c4Schristos    (at your option) any later version.
400*fd82c4c4Schristos 
401*fd82c4c4Schristos    This program is distributed in the hope that it will be useful,
402*fd82c4c4Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
403*fd82c4c4Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
404*fd82c4c4Schristos    General Public License for more details.
405*fd82c4c4Schristos 
406*fd82c4c4Schristos    You should have received a copy of the GNU General Public License
407*fd82c4c4Schristos    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
408*fd82c4c4Schristos 
409*fd82c4c4Schristos /* _GL_WARN_ON_USE (function, "literal string") issues a declaration
410*fd82c4c4Schristos    for FUNCTION which will then trigger a compiler warning containing
411*fd82c4c4Schristos    the text of "literal string" anywhere that function is called, if
412*fd82c4c4Schristos    supported by the compiler.  If the compiler does not support this
413*fd82c4c4Schristos    feature, the macro expands to an unused extern declaration.
414*fd82c4c4Schristos 
415*fd82c4c4Schristos    _GL_WARN_ON_USE_ATTRIBUTE ("literal string") expands to the
416*fd82c4c4Schristos    attribute used in _GL_WARN_ON_USE.  If the compiler does not support
417*fd82c4c4Schristos    this feature, it expands to empty.
418*fd82c4c4Schristos 
419*fd82c4c4Schristos    These macros are useful for marking a function as a potential
420*fd82c4c4Schristos    portability trap, with the intent that "literal string" include
421*fd82c4c4Schristos    instructions on the replacement function that should be used
422*fd82c4c4Schristos    instead.
423*fd82c4c4Schristos    _GL_WARN_ON_USE is for functions with 'extern' linkage.
424*fd82c4c4Schristos    _GL_WARN_ON_USE_ATTRIBUTE is for functions with 'static' or 'inline'
425*fd82c4c4Schristos    linkage.
426*fd82c4c4Schristos 
427*fd82c4c4Schristos    However, one of the reasons that a function is a portability trap is
428*fd82c4c4Schristos    if it has the wrong signature.  Declaring FUNCTION with a different
429*fd82c4c4Schristos    signature in C is a compilation error, so this macro must use the
430*fd82c4c4Schristos    same type as any existing declaration so that programs that avoid
431*fd82c4c4Schristos    the problematic FUNCTION do not fail to compile merely because they
432*fd82c4c4Schristos    included a header that poisoned the function.  But this implies that
433*fd82c4c4Schristos    _GL_WARN_ON_USE is only safe to use if FUNCTION is known to already
434*fd82c4c4Schristos    have a declaration.  Use of this macro implies that there must not
435*fd82c4c4Schristos    be any other macro hiding the declaration of FUNCTION; but
436*fd82c4c4Schristos    undefining FUNCTION first is part of the poisoning process anyway
437*fd82c4c4Schristos    (although for symbols that are provided only via a macro, the result
438*fd82c4c4Schristos    is a compilation error rather than a warning containing
439*fd82c4c4Schristos    "literal string").  Also note that in C++, it is only safe to use if
440*fd82c4c4Schristos    FUNCTION has no overloads.
441*fd82c4c4Schristos 
442*fd82c4c4Schristos    For an example, it is possible to poison 'getline' by:
443*fd82c4c4Schristos    - adding a call to gl_WARN_ON_USE_PREPARE([[#include <stdio.h>]],
444*fd82c4c4Schristos      [getline]) in configure.ac, which potentially defines
445*fd82c4c4Schristos      HAVE_RAW_DECL_GETLINE
446*fd82c4c4Schristos    - adding this code to a header that wraps the system <stdio.h>:
447*fd82c4c4Schristos      #undef getline
448*fd82c4c4Schristos      #if HAVE_RAW_DECL_GETLINE
449*fd82c4c4Schristos      _GL_WARN_ON_USE (getline, "getline is required by POSIX 2008, but"
450*fd82c4c4Schristos        "not universally present; use the gnulib module getline");
451*fd82c4c4Schristos      #endif
452*fd82c4c4Schristos 
453*fd82c4c4Schristos    It is not possible to directly poison global variables.  But it is
454*fd82c4c4Schristos    possible to write a wrapper accessor function, and poison that
455*fd82c4c4Schristos    (less common usage, like &environ, will cause a compilation error
456*fd82c4c4Schristos    rather than issue the nice warning, but the end result of informing
457*fd82c4c4Schristos    the developer about their portability problem is still achieved):
458*fd82c4c4Schristos      #if HAVE_RAW_DECL_ENVIRON
459*fd82c4c4Schristos      static char ***
460*fd82c4c4Schristos      rpl_environ (void) { return &environ; }
461*fd82c4c4Schristos      _GL_WARN_ON_USE (rpl_environ, "environ is not always properly declared");
462*fd82c4c4Schristos      # undef environ
463*fd82c4c4Schristos      # define environ (*rpl_environ ())
464*fd82c4c4Schristos      #endif
465*fd82c4c4Schristos    or better (avoiding contradictory use of 'static' and 'extern'):
466*fd82c4c4Schristos      #if HAVE_RAW_DECL_ENVIRON
467*fd82c4c4Schristos      static char ***
468*fd82c4c4Schristos      _GL_WARN_ON_USE_ATTRIBUTE ("environ is not always properly declared")
469*fd82c4c4Schristos      rpl_environ (void) { return &environ; }
470*fd82c4c4Schristos      # undef environ
471*fd82c4c4Schristos      # define environ (*rpl_environ ())
472*fd82c4c4Schristos      #endif
473*fd82c4c4Schristos    */
474*fd82c4c4Schristos #ifndef _GL_WARN_ON_USE
475*fd82c4c4Schristos 
476*fd82c4c4Schristos # if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
477*fd82c4c4Schristos /* A compiler attribute is available in gcc versions 4.3.0 and later.  */
478*fd82c4c4Schristos #  define _GL_WARN_ON_USE(function, message) \
479*fd82c4c4Schristos extern __typeof__ (function) function __attribute__ ((__warning__ (message)))
480*fd82c4c4Schristos #  define _GL_WARN_ON_USE_ATTRIBUTE(message) \
481*fd82c4c4Schristos   __attribute__ ((__warning__ (message)))
482*fd82c4c4Schristos # elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
483*fd82c4c4Schristos /* Verify the existence of the function.  */
484*fd82c4c4Schristos #  define _GL_WARN_ON_USE(function, message) \
485*fd82c4c4Schristos extern __typeof__ (function) function
486*fd82c4c4Schristos #  define _GL_WARN_ON_USE_ATTRIBUTE(message)
487*fd82c4c4Schristos # else /* Unsupported.  */
488*fd82c4c4Schristos #  define _GL_WARN_ON_USE(function, message) \
489*fd82c4c4Schristos _GL_WARN_EXTERN_C int _gl_warn_on_use
490*fd82c4c4Schristos #  define _GL_WARN_ON_USE_ATTRIBUTE(message)
491*fd82c4c4Schristos # endif
492*fd82c4c4Schristos #endif
493*fd82c4c4Schristos 
494*fd82c4c4Schristos /* _GL_WARN_ON_USE_CXX (function, rettype, parameters_and_attributes, "string")
495*fd82c4c4Schristos    is like _GL_WARN_ON_USE (function, "string"), except that in C++ mode the
496*fd82c4c4Schristos    function is declared with the given prototype, consisting of return type,
497*fd82c4c4Schristos    parameters, and attributes.
498*fd82c4c4Schristos    This variant is useful for overloaded functions in C++. _GL_WARN_ON_USE does
499*fd82c4c4Schristos    not work in this case.  */
500*fd82c4c4Schristos #ifndef _GL_WARN_ON_USE_CXX
501*fd82c4c4Schristos # if !defined __cplusplus
502*fd82c4c4Schristos #  define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
503*fd82c4c4Schristos      _GL_WARN_ON_USE (function, msg)
504*fd82c4c4Schristos # else
505*fd82c4c4Schristos #  if 4 < __GNUC__ || (__GNUC__ == 4 && 3 <= __GNUC_MINOR__)
506*fd82c4c4Schristos #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
507*fd82c4c4Schristos extern rettype function parameters_and_attributes \
508*fd82c4c4Schristos      __attribute__ ((__warning__ (msg)))
509*fd82c4c4Schristos #  elif __GNUC__ >= 3 && GNULIB_STRICT_CHECKING
510*fd82c4c4Schristos /* Verify the existence of the function.  */
511*fd82c4c4Schristos #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
512*fd82c4c4Schristos extern rettype function parameters_and_attributes
513*fd82c4c4Schristos #  else /* Unsupported.  */
514*fd82c4c4Schristos #   define _GL_WARN_ON_USE_CXX(function,rettype,parameters_and_attributes,msg) \
515*fd82c4c4Schristos _GL_WARN_EXTERN_C int _gl_warn_on_use
516*fd82c4c4Schristos #  endif
517*fd82c4c4Schristos # endif
518*fd82c4c4Schristos #endif
519*fd82c4c4Schristos 
520*fd82c4c4Schristos /* _GL_WARN_EXTERN_C declaration;
521*fd82c4c4Schristos    performs the declaration with C linkage.  */
522*fd82c4c4Schristos #ifndef _GL_WARN_EXTERN_C
523*fd82c4c4Schristos # if defined __cplusplus
524*fd82c4c4Schristos #  define _GL_WARN_EXTERN_C extern "C"
525*fd82c4c4Schristos # else
526*fd82c4c4Schristos #  define _GL_WARN_EXTERN_C extern
527*fd82c4c4Schristos # endif
528*fd82c4c4Schristos #endif
529*fd82c4c4Schristos 
530*fd82c4c4Schristos #ifdef __cplusplus
531*fd82c4c4Schristos /* Helper macros to define type-generic function FUNC as overloaded functions,
532*fd82c4c4Schristos    rather than as macros like in C.  POSIX declares these with an argument of
533*fd82c4c4Schristos    real-floating (that is, one of float, double, or long double).  */
534*fd82c4c4Schristos # define _GL_MATH_CXX_REAL_FLOATING_DECL_1(func) \
535*fd82c4c4Schristos static inline int                                                   \
536*fd82c4c4Schristos _gl_cxx_ ## func ## f (float f)                                     \
537*fd82c4c4Schristos {                                                                   \
538*fd82c4c4Schristos   return func (f);                                                  \
539*fd82c4c4Schristos }                                                                   \
540*fd82c4c4Schristos static inline int                                                   \
541*fd82c4c4Schristos _gl_cxx_ ## func ## d (double d)                                    \
542*fd82c4c4Schristos {                                                                   \
543*fd82c4c4Schristos   return func (d);                                                  \
544*fd82c4c4Schristos }                                                                   \
545*fd82c4c4Schristos static inline int                                                   \
546*fd82c4c4Schristos _gl_cxx_ ## func ## l (long double l)                               \
547*fd82c4c4Schristos {                                                                   \
548*fd82c4c4Schristos   return func (l);                                                  \
549*fd82c4c4Schristos }
550*fd82c4c4Schristos # define _GL_MATH_CXX_REAL_FLOATING_DECL_2(func,rpl_func,rettype) \
551*fd82c4c4Schristos _GL_BEGIN_NAMESPACE                                                 \
552*fd82c4c4Schristos inline rettype                                                      \
553*fd82c4c4Schristos rpl_func (float f)                                                  \
554*fd82c4c4Schristos {                                                                   \
555*fd82c4c4Schristos   return _gl_cxx_ ## func ## f (f);                                 \
556*fd82c4c4Schristos }                                                                   \
557*fd82c4c4Schristos inline rettype                                                      \
558*fd82c4c4Schristos rpl_func (double d)                                                 \
559*fd82c4c4Schristos {                                                                   \
560*fd82c4c4Schristos   return _gl_cxx_ ## func ## d (d);                                 \
561*fd82c4c4Schristos }                                                                   \
562*fd82c4c4Schristos inline rettype                                                      \
563*fd82c4c4Schristos rpl_func (long double l)                                            \
564*fd82c4c4Schristos {                                                                   \
565*fd82c4c4Schristos   return _gl_cxx_ ## func ## l (l);                                 \
566*fd82c4c4Schristos }                                                                   \
567*fd82c4c4Schristos _GL_END_NAMESPACE
568*fd82c4c4Schristos #endif
569*fd82c4c4Schristos 
570*fd82c4c4Schristos /* Helper macros to define a portability warning for the
571*fd82c4c4Schristos    classification macro FUNC called with VALUE.  POSIX declares the
572*fd82c4c4Schristos    classification macros with an argument of real-floating (that is,
573*fd82c4c4Schristos    one of float, double, or long double).  */
574*fd82c4c4Schristos #define _GL_WARN_REAL_FLOATING_DECL(func) \
575*fd82c4c4Schristos _GL_MATH_INLINE int                                                       \
576*fd82c4c4Schristos _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - "                      \
577*fd82c4c4Schristos                            "use gnulib module " #func " for portability") \
578*fd82c4c4Schristos rpl_ ## func ## f (float f)                                               \
579*fd82c4c4Schristos {                                                                         \
580*fd82c4c4Schristos   return func (f);                                                        \
581*fd82c4c4Schristos }                                                                         \
582*fd82c4c4Schristos _GL_MATH_INLINE int                                                       \
583*fd82c4c4Schristos _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - "                      \
584*fd82c4c4Schristos                            "use gnulib module " #func " for portability") \
585*fd82c4c4Schristos rpl_ ## func ## d (double d)                                              \
586*fd82c4c4Schristos {                                                                         \
587*fd82c4c4Schristos   return func (d);                                                        \
588*fd82c4c4Schristos }                                                                         \
589*fd82c4c4Schristos _GL_MATH_INLINE int                                                       \
590*fd82c4c4Schristos _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - "                      \
591*fd82c4c4Schristos                            "use gnulib module " #func " for portability") \
592*fd82c4c4Schristos rpl_ ## func ## l (long double l)                                         \
593*fd82c4c4Schristos {                                                                         \
594*fd82c4c4Schristos   return func (l);                                                        \
595*fd82c4c4Schristos }
596*fd82c4c4Schristos #define _GL_WARN_REAL_FLOATING_IMPL(func, value) \
597*fd82c4c4Schristos   (sizeof (value) == sizeof (float) ? rpl_ ## func ## f (value)     \
598*fd82c4c4Schristos    : sizeof (value) == sizeof (double) ? rpl_ ## func ## d (value)  \
599*fd82c4c4Schristos    : rpl_ ## func ## l (value))
600*fd82c4c4Schristos 
601*fd82c4c4Schristos 
602*fd82c4c4Schristos #if 0
603*fd82c4c4Schristos /* Pull in a function that fixes the 'int' to 'long double' conversion
604*fd82c4c4Schristos    of glibc 2.7.  */
605*fd82c4c4Schristos _GL_EXTERN_C void _Qp_itoq (long double *, int);
606*fd82c4c4Schristos static void (*_gl_math_fix_itold) (long double *, int) = _Qp_itoq;
607*fd82c4c4Schristos #endif
608*fd82c4c4Schristos 
609*fd82c4c4Schristos 
610*fd82c4c4Schristos /* For clang: Use __has_builtin to determine whether a builtin is available.  */
611*fd82c4c4Schristos #ifndef __has_builtin
612*fd82c4c4Schristos # define __has_builtin(name) 0
613*fd82c4c4Schristos #endif
614*fd82c4c4Schristos 
615*fd82c4c4Schristos 
616*fd82c4c4Schristos /* POSIX allows platforms that don't support NAN.  But all major
617*fd82c4c4Schristos    machines in the past 15 years have supported something close to
618*fd82c4c4Schristos    IEEE NaN, so we define this unconditionally.  We also must define
619*fd82c4c4Schristos    it on platforms like Solaris 10, where NAN is present but defined
620*fd82c4c4Schristos    as a function pointer rather than a floating point constant.  */
621*fd82c4c4Schristos #if !defined NAN || 0
622*fd82c4c4Schristos # if !GNULIB_defined_NAN
623*fd82c4c4Schristos #  undef NAN
624*fd82c4c4Schristos   /* The Compaq (ex-DEC) C 6.4 compiler and the Microsoft MSVC 9 compiler
625*fd82c4c4Schristos      choke on the expression 0.0 / 0.0.  */
626*fd82c4c4Schristos #  if defined __DECC || defined _MSC_VER
627*fd82c4c4Schristos _GL_MATH_INLINE float
_NaN()628*fd82c4c4Schristos _NaN ()
629*fd82c4c4Schristos {
630*fd82c4c4Schristos   static float zero = 0.0f;
631*fd82c4c4Schristos   return zero / zero;
632*fd82c4c4Schristos }
633*fd82c4c4Schristos #   define NAN (_NaN())
634*fd82c4c4Schristos #  else
635*fd82c4c4Schristos #   define NAN (0.0f / 0.0f)
636*fd82c4c4Schristos #  endif
637*fd82c4c4Schristos #  define GNULIB_defined_NAN 1
638*fd82c4c4Schristos # endif
639*fd82c4c4Schristos #endif
640*fd82c4c4Schristos 
641*fd82c4c4Schristos /* Solaris 10 defines HUGE_VAL, but as a function pointer rather
642*fd82c4c4Schristos    than a floating point constant.  */
643*fd82c4c4Schristos #if 0
644*fd82c4c4Schristos # undef HUGE_VALF
645*fd82c4c4Schristos # define HUGE_VALF (1.0f / 0.0f)
646*fd82c4c4Schristos # undef HUGE_VAL
647*fd82c4c4Schristos # define HUGE_VAL (1.0 / 0.0)
648*fd82c4c4Schristos # undef HUGE_VALL
649*fd82c4c4Schristos # define HUGE_VALL (1.0L / 0.0L)
650*fd82c4c4Schristos #endif
651*fd82c4c4Schristos 
652*fd82c4c4Schristos /* HUGE_VALF is a 'float' Infinity.  */
653*fd82c4c4Schristos #ifndef HUGE_VALF
654*fd82c4c4Schristos # if defined _MSC_VER
655*fd82c4c4Schristos /* The Microsoft MSVC 9 compiler chokes on the expression 1.0f / 0.0f.  */
656*fd82c4c4Schristos #  define HUGE_VALF (1e25f * 1e25f)
657*fd82c4c4Schristos # else
658*fd82c4c4Schristos #  define HUGE_VALF (1.0f / 0.0f)
659*fd82c4c4Schristos # endif
660*fd82c4c4Schristos #endif
661*fd82c4c4Schristos 
662*fd82c4c4Schristos /* HUGE_VAL is a 'double' Infinity.  */
663*fd82c4c4Schristos #ifndef HUGE_VAL
664*fd82c4c4Schristos # if defined _MSC_VER
665*fd82c4c4Schristos /* The Microsoft MSVC 9 compiler chokes on the expression 1.0 / 0.0.  */
666*fd82c4c4Schristos #  define HUGE_VAL (1e250 * 1e250)
667*fd82c4c4Schristos # else
668*fd82c4c4Schristos #  define HUGE_VAL (1.0 / 0.0)
669*fd82c4c4Schristos # endif
670*fd82c4c4Schristos #endif
671*fd82c4c4Schristos 
672*fd82c4c4Schristos /* HUGE_VALL is a 'long double' Infinity.  */
673*fd82c4c4Schristos #ifndef HUGE_VALL
674*fd82c4c4Schristos # if defined _MSC_VER
675*fd82c4c4Schristos /* The Microsoft MSVC 9 compiler chokes on the expression 1.0L / 0.0L.  */
676*fd82c4c4Schristos #  define HUGE_VALL (1e250L * 1e250L)
677*fd82c4c4Schristos # else
678*fd82c4c4Schristos #  define HUGE_VALL (1.0L / 0.0L)
679*fd82c4c4Schristos # endif
680*fd82c4c4Schristos #endif
681*fd82c4c4Schristos 
682*fd82c4c4Schristos 
683*fd82c4c4Schristos #if defined FP_ILOGB0 && defined FP_ILOGBNAN
684*fd82c4c4Schristos  /* Ensure FP_ILOGB0 and FP_ILOGBNAN are correct.  */
685*fd82c4c4Schristos # if defined __HAIKU__
686*fd82c4c4Schristos   /* Haiku: match what ilogb() does */
687*fd82c4c4Schristos #  undef FP_ILOGB0
688*fd82c4c4Schristos #  undef FP_ILOGBNAN
689*fd82c4c4Schristos #  define FP_ILOGB0   (- 2147483647 - 1) /* INT_MIN */
690*fd82c4c4Schristos #  define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
691*fd82c4c4Schristos # endif
692*fd82c4c4Schristos #else
693*fd82c4c4Schristos  /* Ensure FP_ILOGB0 and FP_ILOGBNAN are defined.  */
694*fd82c4c4Schristos # if defined __NetBSD__ || defined __sgi
695*fd82c4c4Schristos   /* NetBSD, IRIX 6.5: match what ilogb() does */
696*fd82c4c4Schristos #  define FP_ILOGB0   (- 2147483647 - 1) /* INT_MIN */
697*fd82c4c4Schristos #  define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
698*fd82c4c4Schristos # elif defined _AIX
699*fd82c4c4Schristos   /* AIX 5.1: match what ilogb() does in AIX >= 5.2 */
700*fd82c4c4Schristos #  define FP_ILOGB0   (- 2147483647 - 1) /* INT_MIN */
701*fd82c4c4Schristos #  define FP_ILOGBNAN 2147483647 /* INT_MAX */
702*fd82c4c4Schristos # elif defined __sun
703*fd82c4c4Schristos   /* Solaris 9: match what ilogb() does */
704*fd82c4c4Schristos #  define FP_ILOGB0   (- 2147483647) /* - INT_MAX */
705*fd82c4c4Schristos #  define FP_ILOGBNAN 2147483647 /* INT_MAX */
706*fd82c4c4Schristos # else
707*fd82c4c4Schristos   /* Gnulib defined values.  */
708*fd82c4c4Schristos #  define FP_ILOGB0   (- 2147483647) /* - INT_MAX */
709*fd82c4c4Schristos #  define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
710*fd82c4c4Schristos # endif
711*fd82c4c4Schristos #endif
712*fd82c4c4Schristos 
713*fd82c4c4Schristos 
714*fd82c4c4Schristos #if 0
715*fd82c4c4Schristos # if 0
716*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
717*fd82c4c4Schristos #   undef acosf
718*fd82c4c4Schristos #   define acosf rpl_acosf
719*fd82c4c4Schristos #  endif
720*fd82c4c4Schristos _GL_FUNCDECL_RPL (acosf, float, (float x));
721*fd82c4c4Schristos _GL_CXXALIAS_RPL (acosf, float, (float x));
722*fd82c4c4Schristos # else
723*fd82c4c4Schristos #  if !1
724*fd82c4c4Schristos #   undef acosf
725*fd82c4c4Schristos _GL_FUNCDECL_SYS (acosf, float, (float x));
726*fd82c4c4Schristos #  endif
727*fd82c4c4Schristos _GL_CXXALIAS_SYS (acosf, float, (float x));
728*fd82c4c4Schristos # endif
729*fd82c4c4Schristos _GL_CXXALIASWARN (acosf);
730*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
731*fd82c4c4Schristos # undef acosf
732*fd82c4c4Schristos # if HAVE_RAW_DECL_ACOSF
733*fd82c4c4Schristos _GL_WARN_ON_USE (acosf, "acosf is unportable - "
734*fd82c4c4Schristos                  "use gnulib module acosf for portability");
735*fd82c4c4Schristos # endif
736*fd82c4c4Schristos #endif
737*fd82c4c4Schristos 
738*fd82c4c4Schristos #if 0
739*fd82c4c4Schristos # if !1 || !1
740*fd82c4c4Schristos #  undef acosl
741*fd82c4c4Schristos _GL_FUNCDECL_SYS (acosl, long double, (long double x));
742*fd82c4c4Schristos # endif
743*fd82c4c4Schristos _GL_CXXALIAS_SYS (acosl, long double, (long double x));
744*fd82c4c4Schristos _GL_CXXALIASWARN (acosl);
745*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
746*fd82c4c4Schristos # undef acosl
747*fd82c4c4Schristos # if HAVE_RAW_DECL_ACOSL
748*fd82c4c4Schristos _GL_WARN_ON_USE (acosl, "acosl is unportable - "
749*fd82c4c4Schristos                  "use gnulib module acosl for portability");
750*fd82c4c4Schristos # endif
751*fd82c4c4Schristos #endif
752*fd82c4c4Schristos 
753*fd82c4c4Schristos 
754*fd82c4c4Schristos #if 0
755*fd82c4c4Schristos # if 0
756*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
757*fd82c4c4Schristos #   undef asinf
758*fd82c4c4Schristos #   define asinf rpl_asinf
759*fd82c4c4Schristos #  endif
760*fd82c4c4Schristos _GL_FUNCDECL_RPL (asinf, float, (float x));
761*fd82c4c4Schristos _GL_CXXALIAS_RPL (asinf, float, (float x));
762*fd82c4c4Schristos # else
763*fd82c4c4Schristos #  if !1
764*fd82c4c4Schristos #   undef asinf
765*fd82c4c4Schristos _GL_FUNCDECL_SYS (asinf, float, (float x));
766*fd82c4c4Schristos #  endif
767*fd82c4c4Schristos _GL_CXXALIAS_SYS (asinf, float, (float x));
768*fd82c4c4Schristos # endif
769*fd82c4c4Schristos _GL_CXXALIASWARN (asinf);
770*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
771*fd82c4c4Schristos # undef asinf
772*fd82c4c4Schristos # if HAVE_RAW_DECL_ASINF
773*fd82c4c4Schristos _GL_WARN_ON_USE (asinf, "asinf is unportable - "
774*fd82c4c4Schristos                  "use gnulib module asinf for portability");
775*fd82c4c4Schristos # endif
776*fd82c4c4Schristos #endif
777*fd82c4c4Schristos 
778*fd82c4c4Schristos #if 0
779*fd82c4c4Schristos # if !1 || !1
780*fd82c4c4Schristos #  undef asinl
781*fd82c4c4Schristos _GL_FUNCDECL_SYS (asinl, long double, (long double x));
782*fd82c4c4Schristos # endif
783*fd82c4c4Schristos _GL_CXXALIAS_SYS (asinl, long double, (long double x));
784*fd82c4c4Schristos _GL_CXXALIASWARN (asinl);
785*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
786*fd82c4c4Schristos # undef asinl
787*fd82c4c4Schristos # if HAVE_RAW_DECL_ASINL
788*fd82c4c4Schristos _GL_WARN_ON_USE (asinl, "asinl is unportable - "
789*fd82c4c4Schristos                  "use gnulib module asinl for portability");
790*fd82c4c4Schristos # endif
791*fd82c4c4Schristos #endif
792*fd82c4c4Schristos 
793*fd82c4c4Schristos 
794*fd82c4c4Schristos #if 0
795*fd82c4c4Schristos # if 0
796*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
797*fd82c4c4Schristos #   undef atanf
798*fd82c4c4Schristos #   define atanf rpl_atanf
799*fd82c4c4Schristos #  endif
800*fd82c4c4Schristos _GL_FUNCDECL_RPL (atanf, float, (float x));
801*fd82c4c4Schristos _GL_CXXALIAS_RPL (atanf, float, (float x));
802*fd82c4c4Schristos # else
803*fd82c4c4Schristos #  if !1
804*fd82c4c4Schristos #   undef atanf
805*fd82c4c4Schristos _GL_FUNCDECL_SYS (atanf, float, (float x));
806*fd82c4c4Schristos #  endif
807*fd82c4c4Schristos _GL_CXXALIAS_SYS (atanf, float, (float x));
808*fd82c4c4Schristos # endif
809*fd82c4c4Schristos _GL_CXXALIASWARN (atanf);
810*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
811*fd82c4c4Schristos # undef atanf
812*fd82c4c4Schristos # if HAVE_RAW_DECL_ATANF
813*fd82c4c4Schristos _GL_WARN_ON_USE (atanf, "atanf is unportable - "
814*fd82c4c4Schristos                  "use gnulib module atanf for portability");
815*fd82c4c4Schristos # endif
816*fd82c4c4Schristos #endif
817*fd82c4c4Schristos 
818*fd82c4c4Schristos #if 0
819*fd82c4c4Schristos # if !1 || !1
820*fd82c4c4Schristos #  undef atanl
821*fd82c4c4Schristos _GL_FUNCDECL_SYS (atanl, long double, (long double x));
822*fd82c4c4Schristos # endif
823*fd82c4c4Schristos _GL_CXXALIAS_SYS (atanl, long double, (long double x));
824*fd82c4c4Schristos _GL_CXXALIASWARN (atanl);
825*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
826*fd82c4c4Schristos # undef atanl
827*fd82c4c4Schristos # if HAVE_RAW_DECL_ATANL
828*fd82c4c4Schristos _GL_WARN_ON_USE (atanl, "atanl is unportable - "
829*fd82c4c4Schristos                  "use gnulib module atanl for portability");
830*fd82c4c4Schristos # endif
831*fd82c4c4Schristos #endif
832*fd82c4c4Schristos 
833*fd82c4c4Schristos 
834*fd82c4c4Schristos #if 0
835*fd82c4c4Schristos # if 0
836*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
837*fd82c4c4Schristos #   undef atan2f
838*fd82c4c4Schristos #   define atan2f rpl_atan2f
839*fd82c4c4Schristos #  endif
840*fd82c4c4Schristos _GL_FUNCDECL_RPL (atan2f, float, (float y, float x));
841*fd82c4c4Schristos _GL_CXXALIAS_RPL (atan2f, float, (float y, float x));
842*fd82c4c4Schristos # else
843*fd82c4c4Schristos #  if !1
844*fd82c4c4Schristos #   undef atan2f
845*fd82c4c4Schristos _GL_FUNCDECL_SYS (atan2f, float, (float y, float x));
846*fd82c4c4Schristos #  endif
847*fd82c4c4Schristos _GL_CXXALIAS_SYS (atan2f, float, (float y, float x));
848*fd82c4c4Schristos # endif
849*fd82c4c4Schristos _GL_CXXALIASWARN (atan2f);
850*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
851*fd82c4c4Schristos # undef atan2f
852*fd82c4c4Schristos # if HAVE_RAW_DECL_ATAN2F
853*fd82c4c4Schristos _GL_WARN_ON_USE (atan2f, "atan2f is unportable - "
854*fd82c4c4Schristos                  "use gnulib module atan2f for portability");
855*fd82c4c4Schristos # endif
856*fd82c4c4Schristos #endif
857*fd82c4c4Schristos 
858*fd82c4c4Schristos 
859*fd82c4c4Schristos #if 0
860*fd82c4c4Schristos # if 0
861*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
862*fd82c4c4Schristos #   undef cbrtf
863*fd82c4c4Schristos #   define cbrtf rpl_cbrtf
864*fd82c4c4Schristos #  endif
865*fd82c4c4Schristos _GL_FUNCDECL_RPL (cbrtf, float, (float x));
866*fd82c4c4Schristos _GL_CXXALIAS_RPL (cbrtf, float, (float x));
867*fd82c4c4Schristos # else
868*fd82c4c4Schristos #  if !1
869*fd82c4c4Schristos _GL_FUNCDECL_SYS (cbrtf, float, (float x));
870*fd82c4c4Schristos #  endif
871*fd82c4c4Schristos _GL_CXXALIAS_SYS (cbrtf, float, (float x));
872*fd82c4c4Schristos # endif
873*fd82c4c4Schristos _GL_CXXALIASWARN (cbrtf);
874*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
875*fd82c4c4Schristos # undef cbrtf
876*fd82c4c4Schristos # if HAVE_RAW_DECL_CBRTF
877*fd82c4c4Schristos _GL_WARN_ON_USE (cbrtf, "cbrtf is unportable - "
878*fd82c4c4Schristos                  "use gnulib module cbrtf for portability");
879*fd82c4c4Schristos # endif
880*fd82c4c4Schristos #endif
881*fd82c4c4Schristos 
882*fd82c4c4Schristos #if 0
883*fd82c4c4Schristos # if !1
884*fd82c4c4Schristos _GL_FUNCDECL_SYS (cbrt, double, (double x));
885*fd82c4c4Schristos # endif
886*fd82c4c4Schristos _GL_CXXALIAS_SYS (cbrt, double, (double x));
887*fd82c4c4Schristos # if __GLIBC__ >= 2
888*fd82c4c4Schristos _GL_CXXALIASWARN (cbrt);
889*fd82c4c4Schristos # endif
890*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
891*fd82c4c4Schristos # undef cbrt
892*fd82c4c4Schristos # if HAVE_RAW_DECL_CBRT
893*fd82c4c4Schristos _GL_WARN_ON_USE (cbrt, "cbrt is unportable - "
894*fd82c4c4Schristos                  "use gnulib module cbrt for portability");
895*fd82c4c4Schristos # endif
896*fd82c4c4Schristos #endif
897*fd82c4c4Schristos 
898*fd82c4c4Schristos #if 0
899*fd82c4c4Schristos # if 0
900*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
901*fd82c4c4Schristos #   undef cbrtl
902*fd82c4c4Schristos #   define cbrtl rpl_cbrtl
903*fd82c4c4Schristos #  endif
904*fd82c4c4Schristos _GL_FUNCDECL_RPL (cbrtl, long double, (long double x));
905*fd82c4c4Schristos _GL_CXXALIAS_RPL (cbrtl, long double, (long double x));
906*fd82c4c4Schristos # else
907*fd82c4c4Schristos #  if !1
908*fd82c4c4Schristos _GL_FUNCDECL_SYS (cbrtl, long double, (long double x));
909*fd82c4c4Schristos #  endif
910*fd82c4c4Schristos _GL_CXXALIAS_SYS (cbrtl, long double, (long double x));
911*fd82c4c4Schristos # endif
912*fd82c4c4Schristos _GL_CXXALIASWARN (cbrtl);
913*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
914*fd82c4c4Schristos # undef cbrtl
915*fd82c4c4Schristos # if HAVE_RAW_DECL_CBRTL
916*fd82c4c4Schristos _GL_WARN_ON_USE (cbrtl, "cbrtl is unportable - "
917*fd82c4c4Schristos                  "use gnulib module cbrtl for portability");
918*fd82c4c4Schristos # endif
919*fd82c4c4Schristos #endif
920*fd82c4c4Schristos 
921*fd82c4c4Schristos 
922*fd82c4c4Schristos #if 0
923*fd82c4c4Schristos # if 0
924*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
925*fd82c4c4Schristos #   undef ceilf
926*fd82c4c4Schristos #   define ceilf rpl_ceilf
927*fd82c4c4Schristos #  endif
928*fd82c4c4Schristos _GL_FUNCDECL_RPL (ceilf, float, (float x));
929*fd82c4c4Schristos _GL_CXXALIAS_RPL (ceilf, float, (float x));
930*fd82c4c4Schristos # else
931*fd82c4c4Schristos #  if !1
932*fd82c4c4Schristos #   undef ceilf
933*fd82c4c4Schristos _GL_FUNCDECL_SYS (ceilf, float, (float x));
934*fd82c4c4Schristos #  endif
935*fd82c4c4Schristos _GL_CXXALIAS_SYS (ceilf, float, (float x));
936*fd82c4c4Schristos # endif
937*fd82c4c4Schristos _GL_CXXALIASWARN (ceilf);
938*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
939*fd82c4c4Schristos # undef ceilf
940*fd82c4c4Schristos # if HAVE_RAW_DECL_CEILF
941*fd82c4c4Schristos _GL_WARN_ON_USE (ceilf, "ceilf is unportable - "
942*fd82c4c4Schristos                  "use gnulib module ceilf for portability");
943*fd82c4c4Schristos # endif
944*fd82c4c4Schristos #endif
945*fd82c4c4Schristos 
946*fd82c4c4Schristos #if 0
947*fd82c4c4Schristos # if 0
948*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
949*fd82c4c4Schristos #   undef ceil
950*fd82c4c4Schristos #   define ceil rpl_ceil
951*fd82c4c4Schristos #  endif
952*fd82c4c4Schristos _GL_FUNCDECL_RPL (ceil, double, (double x));
953*fd82c4c4Schristos _GL_CXXALIAS_RPL (ceil, double, (double x));
954*fd82c4c4Schristos # else
955*fd82c4c4Schristos _GL_CXXALIAS_SYS (ceil, double, (double x));
956*fd82c4c4Schristos # endif
957*fd82c4c4Schristos # if __GLIBC__ >= 2
958*fd82c4c4Schristos _GL_CXXALIASWARN (ceil);
959*fd82c4c4Schristos # endif
960*fd82c4c4Schristos #endif
961*fd82c4c4Schristos 
962*fd82c4c4Schristos #if 0
963*fd82c4c4Schristos # if 0
964*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
965*fd82c4c4Schristos #   undef ceill
966*fd82c4c4Schristos #   define ceill rpl_ceill
967*fd82c4c4Schristos #  endif
968*fd82c4c4Schristos _GL_FUNCDECL_RPL (ceill, long double, (long double x));
969*fd82c4c4Schristos _GL_CXXALIAS_RPL (ceill, long double, (long double x));
970*fd82c4c4Schristos # else
971*fd82c4c4Schristos #  if !1
972*fd82c4c4Schristos #   undef ceill
973*fd82c4c4Schristos _GL_FUNCDECL_SYS (ceill, long double, (long double x));
974*fd82c4c4Schristos #  endif
975*fd82c4c4Schristos _GL_CXXALIAS_SYS (ceill, long double, (long double x));
976*fd82c4c4Schristos # endif
977*fd82c4c4Schristos _GL_CXXALIASWARN (ceill);
978*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
979*fd82c4c4Schristos # undef ceill
980*fd82c4c4Schristos # if HAVE_RAW_DECL_CEILL
981*fd82c4c4Schristos _GL_WARN_ON_USE (ceill, "ceill is unportable - "
982*fd82c4c4Schristos                  "use gnulib module ceill for portability");
983*fd82c4c4Schristos # endif
984*fd82c4c4Schristos #endif
985*fd82c4c4Schristos 
986*fd82c4c4Schristos 
987*fd82c4c4Schristos #if 0
988*fd82c4c4Schristos # if !1
989*fd82c4c4Schristos #  undef copysignf
990*fd82c4c4Schristos _GL_FUNCDECL_SYS (copysignf, float, (float x, float y));
991*fd82c4c4Schristos # endif
992*fd82c4c4Schristos _GL_CXXALIAS_SYS (copysignf, float, (float x, float y));
993*fd82c4c4Schristos _GL_CXXALIASWARN (copysignf);
994*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
995*fd82c4c4Schristos # undef copysignf
996*fd82c4c4Schristos # if HAVE_RAW_DECL_COPYSIGNF
997*fd82c4c4Schristos _GL_WARN_ON_USE (copysignf, "copysignf is unportable - "
998*fd82c4c4Schristos                  "use gnulib module copysignf for portability");
999*fd82c4c4Schristos # endif
1000*fd82c4c4Schristos #endif
1001*fd82c4c4Schristos 
1002*fd82c4c4Schristos #if 0
1003*fd82c4c4Schristos # if !1
1004*fd82c4c4Schristos _GL_FUNCDECL_SYS (copysign, double, (double x, double y));
1005*fd82c4c4Schristos # endif
1006*fd82c4c4Schristos _GL_CXXALIAS_SYS (copysign, double, (double x, double y));
1007*fd82c4c4Schristos # if __GLIBC__ >= 2
1008*fd82c4c4Schristos _GL_CXXALIASWARN (copysign);
1009*fd82c4c4Schristos # endif
1010*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1011*fd82c4c4Schristos # undef copysign
1012*fd82c4c4Schristos # if HAVE_RAW_DECL_COPYSIGN
1013*fd82c4c4Schristos _GL_WARN_ON_USE (copysign, "copysign is unportable - "
1014*fd82c4c4Schristos                  "use gnulib module copysign for portability");
1015*fd82c4c4Schristos # endif
1016*fd82c4c4Schristos #endif
1017*fd82c4c4Schristos 
1018*fd82c4c4Schristos #if 0
1019*fd82c4c4Schristos # if !1
1020*fd82c4c4Schristos _GL_FUNCDECL_SYS (copysignl, long double, (long double x, long double y));
1021*fd82c4c4Schristos # endif
1022*fd82c4c4Schristos _GL_CXXALIAS_SYS (copysignl, long double, (long double x, long double y));
1023*fd82c4c4Schristos _GL_CXXALIASWARN (copysignl);
1024*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1025*fd82c4c4Schristos # undef copysignl
1026*fd82c4c4Schristos # if HAVE_RAW_DECL_COPYSIGNL
1027*fd82c4c4Schristos _GL_WARN_ON_USE (copysign, "copysignl is unportable - "
1028*fd82c4c4Schristos                  "use gnulib module copysignl for portability");
1029*fd82c4c4Schristos # endif
1030*fd82c4c4Schristos #endif
1031*fd82c4c4Schristos 
1032*fd82c4c4Schristos 
1033*fd82c4c4Schristos #if 0
1034*fd82c4c4Schristos # if 0
1035*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1036*fd82c4c4Schristos #   undef cosf
1037*fd82c4c4Schristos #   define cosf rpl_cosf
1038*fd82c4c4Schristos #  endif
1039*fd82c4c4Schristos _GL_FUNCDECL_RPL (cosf, float, (float x));
1040*fd82c4c4Schristos _GL_CXXALIAS_RPL (cosf, float, (float x));
1041*fd82c4c4Schristos # else
1042*fd82c4c4Schristos #  if !1
1043*fd82c4c4Schristos #   undef cosf
1044*fd82c4c4Schristos _GL_FUNCDECL_SYS (cosf, float, (float x));
1045*fd82c4c4Schristos #  endif
1046*fd82c4c4Schristos _GL_CXXALIAS_SYS (cosf, float, (float x));
1047*fd82c4c4Schristos # endif
1048*fd82c4c4Schristos _GL_CXXALIASWARN (cosf);
1049*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1050*fd82c4c4Schristos # undef cosf
1051*fd82c4c4Schristos # if HAVE_RAW_DECL_COSF
1052*fd82c4c4Schristos _GL_WARN_ON_USE (cosf, "cosf is unportable - "
1053*fd82c4c4Schristos                  "use gnulib module cosf for portability");
1054*fd82c4c4Schristos # endif
1055*fd82c4c4Schristos #endif
1056*fd82c4c4Schristos 
1057*fd82c4c4Schristos #if 0
1058*fd82c4c4Schristos # if !1 || !1
1059*fd82c4c4Schristos #  undef cosl
1060*fd82c4c4Schristos _GL_FUNCDECL_SYS (cosl, long double, (long double x));
1061*fd82c4c4Schristos # endif
1062*fd82c4c4Schristos _GL_CXXALIAS_SYS (cosl, long double, (long double x));
1063*fd82c4c4Schristos _GL_CXXALIASWARN (cosl);
1064*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1065*fd82c4c4Schristos # undef cosl
1066*fd82c4c4Schristos # if HAVE_RAW_DECL_COSL
1067*fd82c4c4Schristos _GL_WARN_ON_USE (cosl, "cosl is unportable - "
1068*fd82c4c4Schristos                  "use gnulib module cosl for portability");
1069*fd82c4c4Schristos # endif
1070*fd82c4c4Schristos #endif
1071*fd82c4c4Schristos 
1072*fd82c4c4Schristos 
1073*fd82c4c4Schristos #if 0
1074*fd82c4c4Schristos # if 0
1075*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1076*fd82c4c4Schristos #   undef coshf
1077*fd82c4c4Schristos #   define coshf rpl_coshf
1078*fd82c4c4Schristos #  endif
1079*fd82c4c4Schristos _GL_FUNCDECL_RPL (coshf, float, (float x));
1080*fd82c4c4Schristos _GL_CXXALIAS_RPL (coshf, float, (float x));
1081*fd82c4c4Schristos # else
1082*fd82c4c4Schristos #  if !1
1083*fd82c4c4Schristos #   undef coshf
1084*fd82c4c4Schristos _GL_FUNCDECL_SYS (coshf, float, (float x));
1085*fd82c4c4Schristos #  endif
1086*fd82c4c4Schristos _GL_CXXALIAS_SYS (coshf, float, (float x));
1087*fd82c4c4Schristos # endif
1088*fd82c4c4Schristos _GL_CXXALIASWARN (coshf);
1089*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1090*fd82c4c4Schristos # undef coshf
1091*fd82c4c4Schristos # if HAVE_RAW_DECL_COSHF
1092*fd82c4c4Schristos _GL_WARN_ON_USE (coshf, "coshf is unportable - "
1093*fd82c4c4Schristos                  "use gnulib module coshf for portability");
1094*fd82c4c4Schristos # endif
1095*fd82c4c4Schristos #endif
1096*fd82c4c4Schristos 
1097*fd82c4c4Schristos 
1098*fd82c4c4Schristos #if 0
1099*fd82c4c4Schristos # if 0
1100*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1101*fd82c4c4Schristos #   undef expf
1102*fd82c4c4Schristos #   define expf rpl_expf
1103*fd82c4c4Schristos #  endif
1104*fd82c4c4Schristos _GL_FUNCDECL_RPL (expf, float, (float x));
1105*fd82c4c4Schristos _GL_CXXALIAS_RPL (expf, float, (float x));
1106*fd82c4c4Schristos # else
1107*fd82c4c4Schristos #  if !1
1108*fd82c4c4Schristos #   undef expf
1109*fd82c4c4Schristos _GL_FUNCDECL_SYS (expf, float, (float x));
1110*fd82c4c4Schristos #  endif
1111*fd82c4c4Schristos _GL_CXXALIAS_SYS (expf, float, (float x));
1112*fd82c4c4Schristos # endif
1113*fd82c4c4Schristos _GL_CXXALIASWARN (expf);
1114*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1115*fd82c4c4Schristos # undef expf
1116*fd82c4c4Schristos # if HAVE_RAW_DECL_EXPF
1117*fd82c4c4Schristos _GL_WARN_ON_USE (expf, "expf is unportable - "
1118*fd82c4c4Schristos                  "use gnulib module expf for portability");
1119*fd82c4c4Schristos # endif
1120*fd82c4c4Schristos #endif
1121*fd82c4c4Schristos 
1122*fd82c4c4Schristos #if 0
1123*fd82c4c4Schristos # if 0
1124*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1125*fd82c4c4Schristos #   undef expl
1126*fd82c4c4Schristos #   define expl rpl_expl
1127*fd82c4c4Schristos #  endif
1128*fd82c4c4Schristos _GL_FUNCDECL_RPL (expl, long double, (long double x));
1129*fd82c4c4Schristos _GL_CXXALIAS_RPL (expl, long double, (long double x));
1130*fd82c4c4Schristos # else
1131*fd82c4c4Schristos #  if !1 || !1
1132*fd82c4c4Schristos #   undef expl
1133*fd82c4c4Schristos _GL_FUNCDECL_SYS (expl, long double, (long double x));
1134*fd82c4c4Schristos #  endif
1135*fd82c4c4Schristos _GL_CXXALIAS_SYS (expl, long double, (long double x));
1136*fd82c4c4Schristos # endif
1137*fd82c4c4Schristos _GL_CXXALIASWARN (expl);
1138*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1139*fd82c4c4Schristos # undef expl
1140*fd82c4c4Schristos # if HAVE_RAW_DECL_EXPL
1141*fd82c4c4Schristos _GL_WARN_ON_USE (expl, "expl is unportable - "
1142*fd82c4c4Schristos                  "use gnulib module expl for portability");
1143*fd82c4c4Schristos # endif
1144*fd82c4c4Schristos #endif
1145*fd82c4c4Schristos 
1146*fd82c4c4Schristos 
1147*fd82c4c4Schristos #if 0
1148*fd82c4c4Schristos # if !1
1149*fd82c4c4Schristos _GL_FUNCDECL_SYS (exp2f, float, (float x));
1150*fd82c4c4Schristos # endif
1151*fd82c4c4Schristos _GL_CXXALIAS_SYS (exp2f, float, (float x));
1152*fd82c4c4Schristos _GL_CXXALIASWARN (exp2f);
1153*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1154*fd82c4c4Schristos # undef exp2f
1155*fd82c4c4Schristos # if HAVE_RAW_DECL_EXP2F
1156*fd82c4c4Schristos _GL_WARN_ON_USE (exp2f, "exp2f is unportable - "
1157*fd82c4c4Schristos                  "use gnulib module exp2f for portability");
1158*fd82c4c4Schristos # endif
1159*fd82c4c4Schristos #endif
1160*fd82c4c4Schristos 
1161*fd82c4c4Schristos #if 0
1162*fd82c4c4Schristos # if 0
1163*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1164*fd82c4c4Schristos #   undef exp2
1165*fd82c4c4Schristos #   define exp2 rpl_exp2
1166*fd82c4c4Schristos #  endif
1167*fd82c4c4Schristos _GL_FUNCDECL_RPL (exp2, double, (double x));
1168*fd82c4c4Schristos _GL_CXXALIAS_RPL (exp2, double, (double x));
1169*fd82c4c4Schristos # else
1170*fd82c4c4Schristos #  if !1
1171*fd82c4c4Schristos _GL_FUNCDECL_SYS (exp2, double, (double x));
1172*fd82c4c4Schristos #  endif
1173*fd82c4c4Schristos _GL_CXXALIAS_SYS (exp2, double, (double x));
1174*fd82c4c4Schristos # endif
1175*fd82c4c4Schristos # if __GLIBC__ >= 2
1176*fd82c4c4Schristos _GL_CXXALIASWARN (exp2);
1177*fd82c4c4Schristos # endif
1178*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1179*fd82c4c4Schristos # undef exp2
1180*fd82c4c4Schristos # if HAVE_RAW_DECL_EXP2
1181*fd82c4c4Schristos _GL_WARN_ON_USE (exp2, "exp2 is unportable - "
1182*fd82c4c4Schristos                  "use gnulib module exp2 for portability");
1183*fd82c4c4Schristos # endif
1184*fd82c4c4Schristos #endif
1185*fd82c4c4Schristos 
1186*fd82c4c4Schristos #if 0
1187*fd82c4c4Schristos # if 0
1188*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1189*fd82c4c4Schristos #   undef exp2l
1190*fd82c4c4Schristos #   define exp2l rpl_exp2l
1191*fd82c4c4Schristos #  endif
1192*fd82c4c4Schristos _GL_FUNCDECL_RPL (exp2l, long double, (long double x));
1193*fd82c4c4Schristos _GL_CXXALIAS_RPL (exp2l, long double, (long double x));
1194*fd82c4c4Schristos # else
1195*fd82c4c4Schristos #  if !1
1196*fd82c4c4Schristos #   undef exp2l
1197*fd82c4c4Schristos _GL_FUNCDECL_SYS (exp2l, long double, (long double x));
1198*fd82c4c4Schristos #  endif
1199*fd82c4c4Schristos _GL_CXXALIAS_SYS (exp2l, long double, (long double x));
1200*fd82c4c4Schristos # endif
1201*fd82c4c4Schristos _GL_CXXALIASWARN (exp2l);
1202*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1203*fd82c4c4Schristos # undef exp2l
1204*fd82c4c4Schristos # if HAVE_RAW_DECL_EXP2L
1205*fd82c4c4Schristos _GL_WARN_ON_USE (exp2l, "exp2l is unportable - "
1206*fd82c4c4Schristos                  "use gnulib module exp2l for portability");
1207*fd82c4c4Schristos # endif
1208*fd82c4c4Schristos #endif
1209*fd82c4c4Schristos 
1210*fd82c4c4Schristos 
1211*fd82c4c4Schristos #if 0
1212*fd82c4c4Schristos # if 0
1213*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1214*fd82c4c4Schristos #   undef expm1f
1215*fd82c4c4Schristos #   define expm1f rpl_expm1f
1216*fd82c4c4Schristos #  endif
1217*fd82c4c4Schristos _GL_FUNCDECL_RPL (expm1f, float, (float x));
1218*fd82c4c4Schristos _GL_CXXALIAS_RPL (expm1f, float, (float x));
1219*fd82c4c4Schristos # else
1220*fd82c4c4Schristos #  if !1
1221*fd82c4c4Schristos _GL_FUNCDECL_SYS (expm1f, float, (float x));
1222*fd82c4c4Schristos #  endif
1223*fd82c4c4Schristos _GL_CXXALIAS_SYS (expm1f, float, (float x));
1224*fd82c4c4Schristos # endif
1225*fd82c4c4Schristos _GL_CXXALIASWARN (expm1f);
1226*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1227*fd82c4c4Schristos # undef expm1f
1228*fd82c4c4Schristos # if HAVE_RAW_DECL_EXPM1F
1229*fd82c4c4Schristos _GL_WARN_ON_USE (expm1f, "expm1f is unportable - "
1230*fd82c4c4Schristos                  "use gnulib module expm1f for portability");
1231*fd82c4c4Schristos # endif
1232*fd82c4c4Schristos #endif
1233*fd82c4c4Schristos 
1234*fd82c4c4Schristos #if 0
1235*fd82c4c4Schristos # if 0
1236*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1237*fd82c4c4Schristos #   undef expm1
1238*fd82c4c4Schristos #   define expm1 rpl_expm1
1239*fd82c4c4Schristos #  endif
1240*fd82c4c4Schristos _GL_FUNCDECL_RPL (expm1, double, (double x));
1241*fd82c4c4Schristos _GL_CXXALIAS_RPL (expm1, double, (double x));
1242*fd82c4c4Schristos # else
1243*fd82c4c4Schristos #  if !1
1244*fd82c4c4Schristos _GL_FUNCDECL_SYS (expm1, double, (double x));
1245*fd82c4c4Schristos #  endif
1246*fd82c4c4Schristos _GL_CXXALIAS_SYS (expm1, double, (double x));
1247*fd82c4c4Schristos # endif
1248*fd82c4c4Schristos # if __GLIBC__ >= 2
1249*fd82c4c4Schristos _GL_CXXALIASWARN (expm1);
1250*fd82c4c4Schristos # endif
1251*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1252*fd82c4c4Schristos # undef expm1
1253*fd82c4c4Schristos # if HAVE_RAW_DECL_EXPM1
1254*fd82c4c4Schristos _GL_WARN_ON_USE (expm1, "expm1 is unportable - "
1255*fd82c4c4Schristos                  "use gnulib module expm1 for portability");
1256*fd82c4c4Schristos # endif
1257*fd82c4c4Schristos #endif
1258*fd82c4c4Schristos 
1259*fd82c4c4Schristos #if 0
1260*fd82c4c4Schristos # if 0
1261*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1262*fd82c4c4Schristos #   undef expm1l
1263*fd82c4c4Schristos #   define expm1l rpl_expm1l
1264*fd82c4c4Schristos #  endif
1265*fd82c4c4Schristos _GL_FUNCDECL_RPL (expm1l, long double, (long double x));
1266*fd82c4c4Schristos _GL_CXXALIAS_RPL (expm1l, long double, (long double x));
1267*fd82c4c4Schristos # else
1268*fd82c4c4Schristos #  if !1
1269*fd82c4c4Schristos #   undef expm1l
1270*fd82c4c4Schristos #   if !(defined __cplusplus && defined _AIX)
1271*fd82c4c4Schristos _GL_FUNCDECL_SYS (expm1l, long double, (long double x));
1272*fd82c4c4Schristos #   endif
1273*fd82c4c4Schristos #  endif
1274*fd82c4c4Schristos _GL_CXXALIAS_SYS (expm1l, long double, (long double x));
1275*fd82c4c4Schristos # endif
1276*fd82c4c4Schristos _GL_CXXALIASWARN (expm1l);
1277*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1278*fd82c4c4Schristos # undef expm1l
1279*fd82c4c4Schristos # if HAVE_RAW_DECL_EXPM1L
1280*fd82c4c4Schristos _GL_WARN_ON_USE (expm1l, "expm1l is unportable - "
1281*fd82c4c4Schristos                  "use gnulib module expm1l for portability");
1282*fd82c4c4Schristos # endif
1283*fd82c4c4Schristos #endif
1284*fd82c4c4Schristos 
1285*fd82c4c4Schristos 
1286*fd82c4c4Schristos #if 0
1287*fd82c4c4Schristos # if !1
1288*fd82c4c4Schristos #  undef fabsf
1289*fd82c4c4Schristos _GL_FUNCDECL_SYS (fabsf, float, (float x));
1290*fd82c4c4Schristos # endif
1291*fd82c4c4Schristos _GL_CXXALIAS_SYS (fabsf, float, (float x));
1292*fd82c4c4Schristos _GL_CXXALIASWARN (fabsf);
1293*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1294*fd82c4c4Schristos # undef fabsf
1295*fd82c4c4Schristos # if HAVE_RAW_DECL_FABSF
1296*fd82c4c4Schristos _GL_WARN_ON_USE (fabsf, "fabsf is unportable - "
1297*fd82c4c4Schristos                  "use gnulib module fabsf for portability");
1298*fd82c4c4Schristos # endif
1299*fd82c4c4Schristos #endif
1300*fd82c4c4Schristos 
1301*fd82c4c4Schristos #if 0
1302*fd82c4c4Schristos # if 0
1303*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1304*fd82c4c4Schristos #   undef fabsl
1305*fd82c4c4Schristos #   define fabsl rpl_fabsl
1306*fd82c4c4Schristos #  endif
1307*fd82c4c4Schristos _GL_FUNCDECL_RPL (fabsl, long double, (long double x));
1308*fd82c4c4Schristos _GL_CXXALIAS_RPL (fabsl, long double, (long double x));
1309*fd82c4c4Schristos # else
1310*fd82c4c4Schristos #  if !1
1311*fd82c4c4Schristos #   undef fabsl
1312*fd82c4c4Schristos _GL_FUNCDECL_SYS (fabsl, long double, (long double x));
1313*fd82c4c4Schristos #  endif
1314*fd82c4c4Schristos _GL_CXXALIAS_SYS (fabsl, long double, (long double x));
1315*fd82c4c4Schristos # endif
1316*fd82c4c4Schristos _GL_CXXALIASWARN (fabsl);
1317*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1318*fd82c4c4Schristos # undef fabsl
1319*fd82c4c4Schristos # if HAVE_RAW_DECL_FABSL
1320*fd82c4c4Schristos _GL_WARN_ON_USE (fabsl, "fabsl is unportable - "
1321*fd82c4c4Schristos                  "use gnulib module fabsl for portability");
1322*fd82c4c4Schristos # endif
1323*fd82c4c4Schristos #endif
1324*fd82c4c4Schristos 
1325*fd82c4c4Schristos 
1326*fd82c4c4Schristos #if 0
1327*fd82c4c4Schristos # if 0
1328*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1329*fd82c4c4Schristos #   undef floorf
1330*fd82c4c4Schristos #   define floorf rpl_floorf
1331*fd82c4c4Schristos #  endif
1332*fd82c4c4Schristos _GL_FUNCDECL_RPL (floorf, float, (float x));
1333*fd82c4c4Schristos _GL_CXXALIAS_RPL (floorf, float, (float x));
1334*fd82c4c4Schristos # else
1335*fd82c4c4Schristos #  if !1
1336*fd82c4c4Schristos #   undef floorf
1337*fd82c4c4Schristos _GL_FUNCDECL_SYS (floorf, float, (float x));
1338*fd82c4c4Schristos #  endif
1339*fd82c4c4Schristos _GL_CXXALIAS_SYS (floorf, float, (float x));
1340*fd82c4c4Schristos # endif
1341*fd82c4c4Schristos _GL_CXXALIASWARN (floorf);
1342*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1343*fd82c4c4Schristos # undef floorf
1344*fd82c4c4Schristos # if HAVE_RAW_DECL_FLOORF
1345*fd82c4c4Schristos _GL_WARN_ON_USE (floorf, "floorf is unportable - "
1346*fd82c4c4Schristos                  "use gnulib module floorf for portability");
1347*fd82c4c4Schristos # endif
1348*fd82c4c4Schristos #endif
1349*fd82c4c4Schristos 
1350*fd82c4c4Schristos #if 0
1351*fd82c4c4Schristos # if 0
1352*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1353*fd82c4c4Schristos #   undef floor
1354*fd82c4c4Schristos #   define floor rpl_floor
1355*fd82c4c4Schristos #  endif
1356*fd82c4c4Schristos _GL_FUNCDECL_RPL (floor, double, (double x));
1357*fd82c4c4Schristos _GL_CXXALIAS_RPL (floor, double, (double x));
1358*fd82c4c4Schristos # else
1359*fd82c4c4Schristos _GL_CXXALIAS_SYS (floor, double, (double x));
1360*fd82c4c4Schristos # endif
1361*fd82c4c4Schristos # if __GLIBC__ >= 2
1362*fd82c4c4Schristos _GL_CXXALIASWARN (floor);
1363*fd82c4c4Schristos # endif
1364*fd82c4c4Schristos #endif
1365*fd82c4c4Schristos 
1366*fd82c4c4Schristos #if 0
1367*fd82c4c4Schristos # if 0
1368*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1369*fd82c4c4Schristos #   undef floorl
1370*fd82c4c4Schristos #   define floorl rpl_floorl
1371*fd82c4c4Schristos #  endif
1372*fd82c4c4Schristos _GL_FUNCDECL_RPL (floorl, long double, (long double x));
1373*fd82c4c4Schristos _GL_CXXALIAS_RPL (floorl, long double, (long double x));
1374*fd82c4c4Schristos # else
1375*fd82c4c4Schristos #  if !1
1376*fd82c4c4Schristos #   undef floorl
1377*fd82c4c4Schristos _GL_FUNCDECL_SYS (floorl, long double, (long double x));
1378*fd82c4c4Schristos #  endif
1379*fd82c4c4Schristos _GL_CXXALIAS_SYS (floorl, long double, (long double x));
1380*fd82c4c4Schristos # endif
1381*fd82c4c4Schristos _GL_CXXALIASWARN (floorl);
1382*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1383*fd82c4c4Schristos # undef floorl
1384*fd82c4c4Schristos # if HAVE_RAW_DECL_FLOORL
1385*fd82c4c4Schristos _GL_WARN_ON_USE (floorl, "floorl is unportable - "
1386*fd82c4c4Schristos                  "use gnulib module floorl for portability");
1387*fd82c4c4Schristos # endif
1388*fd82c4c4Schristos #endif
1389*fd82c4c4Schristos 
1390*fd82c4c4Schristos 
1391*fd82c4c4Schristos #if 0
1392*fd82c4c4Schristos # if 0
1393*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1394*fd82c4c4Schristos #   undef fmaf
1395*fd82c4c4Schristos #   define fmaf rpl_fmaf
1396*fd82c4c4Schristos #  endif
1397*fd82c4c4Schristos _GL_FUNCDECL_RPL (fmaf, float, (float x, float y, float z));
1398*fd82c4c4Schristos _GL_CXXALIAS_RPL (fmaf, float, (float x, float y, float z));
1399*fd82c4c4Schristos # else
1400*fd82c4c4Schristos #  if !1
1401*fd82c4c4Schristos #   undef fmaf
1402*fd82c4c4Schristos _GL_FUNCDECL_SYS (fmaf, float, (float x, float y, float z));
1403*fd82c4c4Schristos #  endif
1404*fd82c4c4Schristos _GL_CXXALIAS_SYS (fmaf, float, (float x, float y, float z));
1405*fd82c4c4Schristos # endif
1406*fd82c4c4Schristos _GL_CXXALIASWARN (fmaf);
1407*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1408*fd82c4c4Schristos # undef fmaf
1409*fd82c4c4Schristos # if HAVE_RAW_DECL_FMAF
1410*fd82c4c4Schristos _GL_WARN_ON_USE (fmaf, "fmaf is unportable - "
1411*fd82c4c4Schristos                  "use gnulib module fmaf for portability");
1412*fd82c4c4Schristos # endif
1413*fd82c4c4Schristos #endif
1414*fd82c4c4Schristos 
1415*fd82c4c4Schristos #if 0
1416*fd82c4c4Schristos # if 0
1417*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1418*fd82c4c4Schristos #   undef fma
1419*fd82c4c4Schristos #   define fma rpl_fma
1420*fd82c4c4Schristos #  endif
1421*fd82c4c4Schristos _GL_FUNCDECL_RPL (fma, double, (double x, double y, double z));
1422*fd82c4c4Schristos _GL_CXXALIAS_RPL (fma, double, (double x, double y, double z));
1423*fd82c4c4Schristos # else
1424*fd82c4c4Schristos #  if !1
1425*fd82c4c4Schristos #   undef fma
1426*fd82c4c4Schristos _GL_FUNCDECL_SYS (fma, double, (double x, double y, double z));
1427*fd82c4c4Schristos #  endif
1428*fd82c4c4Schristos _GL_CXXALIAS_SYS (fma, double, (double x, double y, double z));
1429*fd82c4c4Schristos # endif
1430*fd82c4c4Schristos # if __GLIBC__ >= 2
1431*fd82c4c4Schristos _GL_CXXALIASWARN (fma);
1432*fd82c4c4Schristos # endif
1433*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1434*fd82c4c4Schristos # undef fma
1435*fd82c4c4Schristos # if HAVE_RAW_DECL_FMA
1436*fd82c4c4Schristos _GL_WARN_ON_USE (fma, "fma is unportable - "
1437*fd82c4c4Schristos                  "use gnulib module fma for portability");
1438*fd82c4c4Schristos # endif
1439*fd82c4c4Schristos #endif
1440*fd82c4c4Schristos 
1441*fd82c4c4Schristos #if 0
1442*fd82c4c4Schristos # if 0
1443*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1444*fd82c4c4Schristos #   undef fmal
1445*fd82c4c4Schristos #   define fmal rpl_fmal
1446*fd82c4c4Schristos #  endif
1447*fd82c4c4Schristos _GL_FUNCDECL_RPL (fmal, long double,
1448*fd82c4c4Schristos                   (long double x, long double y, long double z));
1449*fd82c4c4Schristos _GL_CXXALIAS_RPL (fmal, long double,
1450*fd82c4c4Schristos                   (long double x, long double y, long double z));
1451*fd82c4c4Schristos # else
1452*fd82c4c4Schristos #  if !1
1453*fd82c4c4Schristos #   undef fmal
1454*fd82c4c4Schristos #   if !(defined __cplusplus && defined _AIX)
1455*fd82c4c4Schristos _GL_FUNCDECL_SYS (fmal, long double,
1456*fd82c4c4Schristos                   (long double x, long double y, long double z));
1457*fd82c4c4Schristos #   endif
1458*fd82c4c4Schristos #  endif
1459*fd82c4c4Schristos _GL_CXXALIAS_SYS (fmal, long double,
1460*fd82c4c4Schristos                   (long double x, long double y, long double z));
1461*fd82c4c4Schristos # endif
1462*fd82c4c4Schristos _GL_CXXALIASWARN (fmal);
1463*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1464*fd82c4c4Schristos # undef fmal
1465*fd82c4c4Schristos # if HAVE_RAW_DECL_FMAL
1466*fd82c4c4Schristos _GL_WARN_ON_USE (fmal, "fmal is unportable - "
1467*fd82c4c4Schristos                  "use gnulib module fmal for portability");
1468*fd82c4c4Schristos # endif
1469*fd82c4c4Schristos #endif
1470*fd82c4c4Schristos 
1471*fd82c4c4Schristos 
1472*fd82c4c4Schristos #if 0
1473*fd82c4c4Schristos # if 0
1474*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1475*fd82c4c4Schristos #   undef fmodf
1476*fd82c4c4Schristos #   define fmodf rpl_fmodf
1477*fd82c4c4Schristos #  endif
1478*fd82c4c4Schristos _GL_FUNCDECL_RPL (fmodf, float, (float x, float y));
1479*fd82c4c4Schristos _GL_CXXALIAS_RPL (fmodf, float, (float x, float y));
1480*fd82c4c4Schristos # else
1481*fd82c4c4Schristos #  if !1
1482*fd82c4c4Schristos #   undef fmodf
1483*fd82c4c4Schristos _GL_FUNCDECL_SYS (fmodf, float, (float x, float y));
1484*fd82c4c4Schristos #  endif
1485*fd82c4c4Schristos _GL_CXXALIAS_SYS (fmodf, float, (float x, float y));
1486*fd82c4c4Schristos # endif
1487*fd82c4c4Schristos _GL_CXXALIASWARN (fmodf);
1488*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1489*fd82c4c4Schristos # undef fmodf
1490*fd82c4c4Schristos # if HAVE_RAW_DECL_FMODF
1491*fd82c4c4Schristos _GL_WARN_ON_USE (fmodf, "fmodf is unportable - "
1492*fd82c4c4Schristos                  "use gnulib module fmodf for portability");
1493*fd82c4c4Schristos # endif
1494*fd82c4c4Schristos #endif
1495*fd82c4c4Schristos 
1496*fd82c4c4Schristos #if 0
1497*fd82c4c4Schristos # if 0
1498*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1499*fd82c4c4Schristos #   undef fmod
1500*fd82c4c4Schristos #   define fmod rpl_fmod
1501*fd82c4c4Schristos #  endif
1502*fd82c4c4Schristos _GL_FUNCDECL_RPL (fmod, double, (double x, double y));
1503*fd82c4c4Schristos _GL_CXXALIAS_RPL (fmod, double, (double x, double y));
1504*fd82c4c4Schristos # else
1505*fd82c4c4Schristos _GL_CXXALIAS_SYS (fmod, double, (double x, double y));
1506*fd82c4c4Schristos # endif
1507*fd82c4c4Schristos # if __GLIBC__ >= 2
1508*fd82c4c4Schristos _GL_CXXALIASWARN (fmod);
1509*fd82c4c4Schristos # endif
1510*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1511*fd82c4c4Schristos # undef fmod
1512*fd82c4c4Schristos # if HAVE_RAW_DECL_FMOD
1513*fd82c4c4Schristos _GL_WARN_ON_USE (fmod, "fmod has portability problems - "
1514*fd82c4c4Schristos                  "use gnulib module fmod for portability");
1515*fd82c4c4Schristos # endif
1516*fd82c4c4Schristos #endif
1517*fd82c4c4Schristos 
1518*fd82c4c4Schristos #if 0
1519*fd82c4c4Schristos # if 0
1520*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1521*fd82c4c4Schristos #   undef fmodl
1522*fd82c4c4Schristos #   define fmodl rpl_fmodl
1523*fd82c4c4Schristos #  endif
1524*fd82c4c4Schristos _GL_FUNCDECL_RPL (fmodl, long double, (long double x, long double y));
1525*fd82c4c4Schristos _GL_CXXALIAS_RPL (fmodl, long double, (long double x, long double y));
1526*fd82c4c4Schristos # else
1527*fd82c4c4Schristos #  if !1
1528*fd82c4c4Schristos #   undef fmodl
1529*fd82c4c4Schristos _GL_FUNCDECL_SYS (fmodl, long double, (long double x, long double y));
1530*fd82c4c4Schristos #  endif
1531*fd82c4c4Schristos _GL_CXXALIAS_SYS (fmodl, long double, (long double x, long double y));
1532*fd82c4c4Schristos # endif
1533*fd82c4c4Schristos _GL_CXXALIASWARN (fmodl);
1534*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1535*fd82c4c4Schristos # undef fmodl
1536*fd82c4c4Schristos # if HAVE_RAW_DECL_FMODL
1537*fd82c4c4Schristos _GL_WARN_ON_USE (fmodl, "fmodl is unportable - "
1538*fd82c4c4Schristos                  "use gnulib module fmodl for portability");
1539*fd82c4c4Schristos # endif
1540*fd82c4c4Schristos #endif
1541*fd82c4c4Schristos 
1542*fd82c4c4Schristos 
1543*fd82c4c4Schristos /* Write x as
1544*fd82c4c4Schristos      x = mantissa * 2^exp
1545*fd82c4c4Schristos    where
1546*fd82c4c4Schristos      If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1547*fd82c4c4Schristos      If x is zero: mantissa = x, exp = 0.
1548*fd82c4c4Schristos      If x is infinite or NaN: mantissa = x, exp unspecified.
1549*fd82c4c4Schristos    Store exp in *EXPPTR and return mantissa.  */
1550*fd82c4c4Schristos #if 0
1551*fd82c4c4Schristos # if 0
1552*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1553*fd82c4c4Schristos #   undef frexpf
1554*fd82c4c4Schristos #   define frexpf rpl_frexpf
1555*fd82c4c4Schristos #  endif
1556*fd82c4c4Schristos _GL_FUNCDECL_RPL (frexpf, float, (float x, int *expptr) _GL_ARG_NONNULL ((2)));
1557*fd82c4c4Schristos _GL_CXXALIAS_RPL (frexpf, float, (float x, int *expptr));
1558*fd82c4c4Schristos # else
1559*fd82c4c4Schristos #  if !1
1560*fd82c4c4Schristos #   undef frexpf
1561*fd82c4c4Schristos _GL_FUNCDECL_SYS (frexpf, float, (float x, int *expptr) _GL_ARG_NONNULL ((2)));
1562*fd82c4c4Schristos #  endif
1563*fd82c4c4Schristos _GL_CXXALIAS_SYS (frexpf, float, (float x, int *expptr));
1564*fd82c4c4Schristos # endif
1565*fd82c4c4Schristos _GL_CXXALIASWARN (frexpf);
1566*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1567*fd82c4c4Schristos # undef frexpf
1568*fd82c4c4Schristos # if HAVE_RAW_DECL_FREXPF
1569*fd82c4c4Schristos _GL_WARN_ON_USE (frexpf, "frexpf is unportable - "
1570*fd82c4c4Schristos                  "use gnulib module frexpf for portability");
1571*fd82c4c4Schristos # endif
1572*fd82c4c4Schristos #endif
1573*fd82c4c4Schristos 
1574*fd82c4c4Schristos /* Write x as
1575*fd82c4c4Schristos      x = mantissa * 2^exp
1576*fd82c4c4Schristos    where
1577*fd82c4c4Schristos      If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1578*fd82c4c4Schristos      If x is zero: mantissa = x, exp = 0.
1579*fd82c4c4Schristos      If x is infinite or NaN: mantissa = x, exp unspecified.
1580*fd82c4c4Schristos    Store exp in *EXPPTR and return mantissa.  */
1581*fd82c4c4Schristos #if 1
1582*fd82c4c4Schristos # if 0
1583*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1584*fd82c4c4Schristos #   undef frexp
1585*fd82c4c4Schristos #   define frexp rpl_frexp
1586*fd82c4c4Schristos #  endif
1587*fd82c4c4Schristos _GL_FUNCDECL_RPL (frexp, double, (double x, int *expptr) _GL_ARG_NONNULL ((2)));
1588*fd82c4c4Schristos _GL_CXXALIAS_RPL (frexp, double, (double x, int *expptr));
1589*fd82c4c4Schristos # else
1590*fd82c4c4Schristos _GL_CXXALIAS_SYS (frexp, double, (double x, int *expptr));
1591*fd82c4c4Schristos # endif
1592*fd82c4c4Schristos # if __GLIBC__ >= 2
1593*fd82c4c4Schristos _GL_CXXALIASWARN1 (frexp, double, (double x, int *expptr));
1594*fd82c4c4Schristos # endif
1595*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1596*fd82c4c4Schristos # undef frexp
1597*fd82c4c4Schristos /* Assume frexp is always declared.  */
1598*fd82c4c4Schristos _GL_WARN_ON_USE (frexp, "frexp is unportable - "
1599*fd82c4c4Schristos                  "use gnulib module frexp for portability");
1600*fd82c4c4Schristos #endif
1601*fd82c4c4Schristos 
1602*fd82c4c4Schristos /* Write x as
1603*fd82c4c4Schristos      x = mantissa * 2^exp
1604*fd82c4c4Schristos    where
1605*fd82c4c4Schristos      If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1606*fd82c4c4Schristos      If x is zero: mantissa = x, exp = 0.
1607*fd82c4c4Schristos      If x is infinite or NaN: mantissa = x, exp unspecified.
1608*fd82c4c4Schristos    Store exp in *EXPPTR and return mantissa.  */
1609*fd82c4c4Schristos #if 1 && 0
1610*fd82c4c4Schristos # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1611*fd82c4c4Schristos #  undef frexpl
1612*fd82c4c4Schristos #  define frexpl rpl_frexpl
1613*fd82c4c4Schristos # endif
1614*fd82c4c4Schristos _GL_FUNCDECL_RPL (frexpl, long double,
1615*fd82c4c4Schristos                   (long double x, int *expptr) _GL_ARG_NONNULL ((2)));
1616*fd82c4c4Schristos _GL_CXXALIAS_RPL (frexpl, long double, (long double x, int *expptr));
1617*fd82c4c4Schristos #else
1618*fd82c4c4Schristos # if !1
1619*fd82c4c4Schristos _GL_FUNCDECL_SYS (frexpl, long double,
1620*fd82c4c4Schristos                   (long double x, int *expptr) _GL_ARG_NONNULL ((2)));
1621*fd82c4c4Schristos # endif
1622*fd82c4c4Schristos # if 1
1623*fd82c4c4Schristos _GL_CXXALIAS_SYS (frexpl, long double, (long double x, int *expptr));
1624*fd82c4c4Schristos # endif
1625*fd82c4c4Schristos #endif
1626*fd82c4c4Schristos #if 1 && !(0 && !1)
1627*fd82c4c4Schristos _GL_CXXALIASWARN (frexpl);
1628*fd82c4c4Schristos #endif
1629*fd82c4c4Schristos #if !1 && defined GNULIB_POSIXCHECK
1630*fd82c4c4Schristos # undef frexpl
1631*fd82c4c4Schristos # if HAVE_RAW_DECL_FREXPL
1632*fd82c4c4Schristos _GL_WARN_ON_USE (frexpl, "frexpl is unportable - "
1633*fd82c4c4Schristos                  "use gnulib module frexpl for portability");
1634*fd82c4c4Schristos # endif
1635*fd82c4c4Schristos #endif
1636*fd82c4c4Schristos 
1637*fd82c4c4Schristos 
1638*fd82c4c4Schristos /* Return sqrt(x^2+y^2).  */
1639*fd82c4c4Schristos #if 0
1640*fd82c4c4Schristos # if 0
1641*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1642*fd82c4c4Schristos #   undef hypotf
1643*fd82c4c4Schristos #   define hypotf rpl_hypotf
1644*fd82c4c4Schristos #  endif
1645*fd82c4c4Schristos _GL_FUNCDECL_RPL (hypotf, float, (float x, float y));
1646*fd82c4c4Schristos _GL_CXXALIAS_RPL (hypotf, float, (float x, float y));
1647*fd82c4c4Schristos # else
1648*fd82c4c4Schristos #  if !1
1649*fd82c4c4Schristos _GL_FUNCDECL_SYS (hypotf, float, (float x, float y));
1650*fd82c4c4Schristos #  endif
1651*fd82c4c4Schristos _GL_CXXALIAS_SYS (hypotf, float, (float x, float y));
1652*fd82c4c4Schristos # endif
1653*fd82c4c4Schristos _GL_CXXALIASWARN (hypotf);
1654*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1655*fd82c4c4Schristos # undef hypotf
1656*fd82c4c4Schristos # if HAVE_RAW_DECL_HYPOTF
1657*fd82c4c4Schristos _GL_WARN_ON_USE (hypotf, "hypotf is unportable - "
1658*fd82c4c4Schristos                  "use gnulib module hypotf for portability");
1659*fd82c4c4Schristos # endif
1660*fd82c4c4Schristos #endif
1661*fd82c4c4Schristos 
1662*fd82c4c4Schristos /* Return sqrt(x^2+y^2).  */
1663*fd82c4c4Schristos #if 0
1664*fd82c4c4Schristos # if 0
1665*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1666*fd82c4c4Schristos #   undef hypot
1667*fd82c4c4Schristos #   define hypot rpl_hypot
1668*fd82c4c4Schristos #  endif
1669*fd82c4c4Schristos _GL_FUNCDECL_RPL (hypot, double, (double x, double y));
1670*fd82c4c4Schristos _GL_CXXALIAS_RPL (hypot, double, (double x, double y));
1671*fd82c4c4Schristos # else
1672*fd82c4c4Schristos _GL_CXXALIAS_SYS (hypot, double, (double x, double y));
1673*fd82c4c4Schristos # endif
1674*fd82c4c4Schristos # if __GLIBC__ >= 2
1675*fd82c4c4Schristos _GL_CXXALIASWARN (hypot);
1676*fd82c4c4Schristos # endif
1677*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1678*fd82c4c4Schristos # undef hypot
1679*fd82c4c4Schristos # if HAVE_RAW_DECL_HYPOT
1680*fd82c4c4Schristos _GL_WARN_ON_USE (hypotf, "hypot has portability problems - "
1681*fd82c4c4Schristos                  "use gnulib module hypot for portability");
1682*fd82c4c4Schristos # endif
1683*fd82c4c4Schristos #endif
1684*fd82c4c4Schristos 
1685*fd82c4c4Schristos /* Return sqrt(x^2+y^2).  */
1686*fd82c4c4Schristos #if 0
1687*fd82c4c4Schristos # if 0
1688*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1689*fd82c4c4Schristos #   undef hypotl
1690*fd82c4c4Schristos #   define hypotl rpl_hypotl
1691*fd82c4c4Schristos #  endif
1692*fd82c4c4Schristos _GL_FUNCDECL_RPL (hypotl, long double, (long double x, long double y));
1693*fd82c4c4Schristos _GL_CXXALIAS_RPL (hypotl, long double, (long double x, long double y));
1694*fd82c4c4Schristos # else
1695*fd82c4c4Schristos #  if !1
1696*fd82c4c4Schristos _GL_FUNCDECL_SYS (hypotl, long double, (long double x, long double y));
1697*fd82c4c4Schristos #  endif
1698*fd82c4c4Schristos _GL_CXXALIAS_SYS (hypotl, long double, (long double x, long double y));
1699*fd82c4c4Schristos # endif
1700*fd82c4c4Schristos _GL_CXXALIASWARN (hypotl);
1701*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1702*fd82c4c4Schristos # undef hypotl
1703*fd82c4c4Schristos # if HAVE_RAW_DECL_HYPOTL
1704*fd82c4c4Schristos _GL_WARN_ON_USE (hypotl, "hypotl is unportable - "
1705*fd82c4c4Schristos                  "use gnulib module hypotl for portability");
1706*fd82c4c4Schristos # endif
1707*fd82c4c4Schristos #endif
1708*fd82c4c4Schristos 
1709*fd82c4c4Schristos 
1710*fd82c4c4Schristos #if 0
1711*fd82c4c4Schristos # if 0
1712*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1713*fd82c4c4Schristos #   undef ilogbf
1714*fd82c4c4Schristos #   define ilogbf rpl_ilogbf
1715*fd82c4c4Schristos #  endif
1716*fd82c4c4Schristos _GL_FUNCDECL_RPL (ilogbf, int, (float x));
1717*fd82c4c4Schristos _GL_CXXALIAS_RPL (ilogbf, int, (float x));
1718*fd82c4c4Schristos # else
1719*fd82c4c4Schristos #  if !1
1720*fd82c4c4Schristos _GL_FUNCDECL_SYS (ilogbf, int, (float x));
1721*fd82c4c4Schristos #  endif
1722*fd82c4c4Schristos _GL_CXXALIAS_SYS (ilogbf, int, (float x));
1723*fd82c4c4Schristos # endif
1724*fd82c4c4Schristos _GL_CXXALIASWARN (ilogbf);
1725*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1726*fd82c4c4Schristos # undef ilogbf
1727*fd82c4c4Schristos # if HAVE_RAW_DECL_ILOGBF
1728*fd82c4c4Schristos _GL_WARN_ON_USE (ilogbf, "ilogbf is unportable - "
1729*fd82c4c4Schristos                  "use gnulib module ilogbf for portability");
1730*fd82c4c4Schristos # endif
1731*fd82c4c4Schristos #endif
1732*fd82c4c4Schristos 
1733*fd82c4c4Schristos #if 0
1734*fd82c4c4Schristos # if 0
1735*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1736*fd82c4c4Schristos #   undef ilogb
1737*fd82c4c4Schristos #   define ilogb rpl_ilogb
1738*fd82c4c4Schristos #  endif
1739*fd82c4c4Schristos _GL_FUNCDECL_RPL (ilogb, int, (double x));
1740*fd82c4c4Schristos _GL_CXXALIAS_RPL (ilogb, int, (double x));
1741*fd82c4c4Schristos # else
1742*fd82c4c4Schristos #  if !1
1743*fd82c4c4Schristos _GL_FUNCDECL_SYS (ilogb, int, (double x));
1744*fd82c4c4Schristos #  endif
1745*fd82c4c4Schristos _GL_CXXALIAS_SYS (ilogb, int, (double x));
1746*fd82c4c4Schristos # endif
1747*fd82c4c4Schristos # if __GLIBC__ >= 2
1748*fd82c4c4Schristos _GL_CXXALIASWARN (ilogb);
1749*fd82c4c4Schristos # endif
1750*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1751*fd82c4c4Schristos # undef ilogb
1752*fd82c4c4Schristos # if HAVE_RAW_DECL_ILOGB
1753*fd82c4c4Schristos _GL_WARN_ON_USE (ilogb, "ilogb is unportable - "
1754*fd82c4c4Schristos                  "use gnulib module ilogb for portability");
1755*fd82c4c4Schristos # endif
1756*fd82c4c4Schristos #endif
1757*fd82c4c4Schristos 
1758*fd82c4c4Schristos #if 0
1759*fd82c4c4Schristos # if 0
1760*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1761*fd82c4c4Schristos #   undef ilogbl
1762*fd82c4c4Schristos #   define ilogbl rpl_ilogbl
1763*fd82c4c4Schristos #  endif
1764*fd82c4c4Schristos _GL_FUNCDECL_RPL (ilogbl, int, (long double x));
1765*fd82c4c4Schristos _GL_CXXALIAS_RPL (ilogbl, int, (long double x));
1766*fd82c4c4Schristos # else
1767*fd82c4c4Schristos #  if !1
1768*fd82c4c4Schristos _GL_FUNCDECL_SYS (ilogbl, int, (long double x));
1769*fd82c4c4Schristos #  endif
1770*fd82c4c4Schristos _GL_CXXALIAS_SYS (ilogbl, int, (long double x));
1771*fd82c4c4Schristos # endif
1772*fd82c4c4Schristos _GL_CXXALIASWARN (ilogbl);
1773*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1774*fd82c4c4Schristos # undef ilogbl
1775*fd82c4c4Schristos # if HAVE_RAW_DECL_ILOGBL
1776*fd82c4c4Schristos _GL_WARN_ON_USE (ilogbl, "ilogbl is unportable - "
1777*fd82c4c4Schristos                  "use gnulib module ilogbl for portability");
1778*fd82c4c4Schristos # endif
1779*fd82c4c4Schristos #endif
1780*fd82c4c4Schristos 
1781*fd82c4c4Schristos 
1782*fd82c4c4Schristos /* Return x * 2^exp.  */
1783*fd82c4c4Schristos #if 0
1784*fd82c4c4Schristos # if !1
1785*fd82c4c4Schristos #  undef ldexpf
1786*fd82c4c4Schristos _GL_FUNCDECL_SYS (ldexpf, float, (float x, int exp));
1787*fd82c4c4Schristos # endif
1788*fd82c4c4Schristos _GL_CXXALIAS_SYS (ldexpf, float, (float x, int exp));
1789*fd82c4c4Schristos _GL_CXXALIASWARN (ldexpf);
1790*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1791*fd82c4c4Schristos # undef ldexpf
1792*fd82c4c4Schristos # if HAVE_RAW_DECL_LDEXPF
1793*fd82c4c4Schristos _GL_WARN_ON_USE (ldexpf, "ldexpf is unportable - "
1794*fd82c4c4Schristos                  "use gnulib module ldexpf for portability");
1795*fd82c4c4Schristos # endif
1796*fd82c4c4Schristos #endif
1797*fd82c4c4Schristos 
1798*fd82c4c4Schristos /* Return x * 2^exp.  */
1799*fd82c4c4Schristos #if 0 && 0
1800*fd82c4c4Schristos # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1801*fd82c4c4Schristos #  undef ldexpl
1802*fd82c4c4Schristos #  define ldexpl rpl_ldexpl
1803*fd82c4c4Schristos # endif
1804*fd82c4c4Schristos _GL_FUNCDECL_RPL (ldexpl, long double, (long double x, int exp));
1805*fd82c4c4Schristos _GL_CXXALIAS_RPL (ldexpl, long double, (long double x, int exp));
1806*fd82c4c4Schristos #else
1807*fd82c4c4Schristos # if !1
1808*fd82c4c4Schristos _GL_FUNCDECL_SYS (ldexpl, long double, (long double x, int exp));
1809*fd82c4c4Schristos # endif
1810*fd82c4c4Schristos # if 0
1811*fd82c4c4Schristos _GL_CXXALIAS_SYS (ldexpl, long double, (long double x, int exp));
1812*fd82c4c4Schristos # endif
1813*fd82c4c4Schristos #endif
1814*fd82c4c4Schristos #if 0
1815*fd82c4c4Schristos _GL_CXXALIASWARN (ldexpl);
1816*fd82c4c4Schristos #endif
1817*fd82c4c4Schristos #if !0 && defined GNULIB_POSIXCHECK
1818*fd82c4c4Schristos # undef ldexpl
1819*fd82c4c4Schristos # if HAVE_RAW_DECL_LDEXPL
1820*fd82c4c4Schristos _GL_WARN_ON_USE (ldexpl, "ldexpl is unportable - "
1821*fd82c4c4Schristos                  "use gnulib module ldexpl for portability");
1822*fd82c4c4Schristos # endif
1823*fd82c4c4Schristos #endif
1824*fd82c4c4Schristos 
1825*fd82c4c4Schristos 
1826*fd82c4c4Schristos #if 0
1827*fd82c4c4Schristos # if 0
1828*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1829*fd82c4c4Schristos #   undef logf
1830*fd82c4c4Schristos #   define logf rpl_logf
1831*fd82c4c4Schristos #  endif
1832*fd82c4c4Schristos _GL_FUNCDECL_RPL (logf, float, (float x));
1833*fd82c4c4Schristos _GL_CXXALIAS_RPL (logf, float, (float x));
1834*fd82c4c4Schristos # else
1835*fd82c4c4Schristos #  if !1
1836*fd82c4c4Schristos #   undef logf
1837*fd82c4c4Schristos _GL_FUNCDECL_SYS (logf, float, (float x));
1838*fd82c4c4Schristos #  endif
1839*fd82c4c4Schristos _GL_CXXALIAS_SYS (logf, float, (float x));
1840*fd82c4c4Schristos # endif
1841*fd82c4c4Schristos _GL_CXXALIASWARN (logf);
1842*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1843*fd82c4c4Schristos # undef logf
1844*fd82c4c4Schristos # if HAVE_RAW_DECL_LOGF
1845*fd82c4c4Schristos _GL_WARN_ON_USE (logf, "logf is unportable - "
1846*fd82c4c4Schristos                  "use gnulib module logf for portability");
1847*fd82c4c4Schristos # endif
1848*fd82c4c4Schristos #endif
1849*fd82c4c4Schristos 
1850*fd82c4c4Schristos #if 0
1851*fd82c4c4Schristos # if 0
1852*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1853*fd82c4c4Schristos #   undef log
1854*fd82c4c4Schristos #   define log rpl_log
1855*fd82c4c4Schristos #  endif
1856*fd82c4c4Schristos _GL_FUNCDECL_RPL (log, double, (double x));
1857*fd82c4c4Schristos _GL_CXXALIAS_RPL (log, double, (double x));
1858*fd82c4c4Schristos # else
1859*fd82c4c4Schristos _GL_CXXALIAS_SYS (log, double, (double x));
1860*fd82c4c4Schristos # endif
1861*fd82c4c4Schristos # if __GLIBC__ >= 2
1862*fd82c4c4Schristos _GL_CXXALIASWARN (log);
1863*fd82c4c4Schristos # endif
1864*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1865*fd82c4c4Schristos # undef log
1866*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG
1867*fd82c4c4Schristos _GL_WARN_ON_USE (log, "log has portability problems - "
1868*fd82c4c4Schristos                  "use gnulib module log for portability");
1869*fd82c4c4Schristos # endif
1870*fd82c4c4Schristos #endif
1871*fd82c4c4Schristos 
1872*fd82c4c4Schristos #if 0
1873*fd82c4c4Schristos # if 0
1874*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1875*fd82c4c4Schristos #   undef logl
1876*fd82c4c4Schristos #   define logl rpl_logl
1877*fd82c4c4Schristos #  endif
1878*fd82c4c4Schristos _GL_FUNCDECL_RPL (logl, long double, (long double x));
1879*fd82c4c4Schristos _GL_CXXALIAS_RPL (logl, long double, (long double x));
1880*fd82c4c4Schristos # else
1881*fd82c4c4Schristos #  if !1 || !1
1882*fd82c4c4Schristos #   undef logl
1883*fd82c4c4Schristos _GL_FUNCDECL_SYS (logl, long double, (long double x));
1884*fd82c4c4Schristos #  endif
1885*fd82c4c4Schristos _GL_CXXALIAS_SYS (logl, long double, (long double x));
1886*fd82c4c4Schristos # endif
1887*fd82c4c4Schristos _GL_CXXALIASWARN (logl);
1888*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1889*fd82c4c4Schristos # undef logl
1890*fd82c4c4Schristos # if HAVE_RAW_DECL_LOGL
1891*fd82c4c4Schristos _GL_WARN_ON_USE (logl, "logl is unportable - "
1892*fd82c4c4Schristos                  "use gnulib module logl for portability");
1893*fd82c4c4Schristos # endif
1894*fd82c4c4Schristos #endif
1895*fd82c4c4Schristos 
1896*fd82c4c4Schristos 
1897*fd82c4c4Schristos #if 0
1898*fd82c4c4Schristos # if 0
1899*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1900*fd82c4c4Schristos #   undef log10f
1901*fd82c4c4Schristos #   define log10f rpl_log10f
1902*fd82c4c4Schristos #  endif
1903*fd82c4c4Schristos _GL_FUNCDECL_RPL (log10f, float, (float x));
1904*fd82c4c4Schristos _GL_CXXALIAS_RPL (log10f, float, (float x));
1905*fd82c4c4Schristos # else
1906*fd82c4c4Schristos #  if !1
1907*fd82c4c4Schristos #   undef log10f
1908*fd82c4c4Schristos _GL_FUNCDECL_SYS (log10f, float, (float x));
1909*fd82c4c4Schristos #  endif
1910*fd82c4c4Schristos _GL_CXXALIAS_SYS (log10f, float, (float x));
1911*fd82c4c4Schristos # endif
1912*fd82c4c4Schristos _GL_CXXALIASWARN (log10f);
1913*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1914*fd82c4c4Schristos # undef log10f
1915*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG10F
1916*fd82c4c4Schristos _GL_WARN_ON_USE (log10f, "log10f is unportable - "
1917*fd82c4c4Schristos                  "use gnulib module log10f for portability");
1918*fd82c4c4Schristos # endif
1919*fd82c4c4Schristos #endif
1920*fd82c4c4Schristos 
1921*fd82c4c4Schristos #if 0
1922*fd82c4c4Schristos # if 0
1923*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1924*fd82c4c4Schristos #   undef log10
1925*fd82c4c4Schristos #   define log10 rpl_log10
1926*fd82c4c4Schristos #  endif
1927*fd82c4c4Schristos _GL_FUNCDECL_RPL (log10, double, (double x));
1928*fd82c4c4Schristos _GL_CXXALIAS_RPL (log10, double, (double x));
1929*fd82c4c4Schristos # else
1930*fd82c4c4Schristos _GL_CXXALIAS_SYS (log10, double, (double x));
1931*fd82c4c4Schristos # endif
1932*fd82c4c4Schristos # if __GLIBC__ >= 2
1933*fd82c4c4Schristos _GL_CXXALIASWARN (log10);
1934*fd82c4c4Schristos # endif
1935*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1936*fd82c4c4Schristos # undef log10
1937*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG10
1938*fd82c4c4Schristos _GL_WARN_ON_USE (log10, "log10 has portability problems - "
1939*fd82c4c4Schristos                  "use gnulib module log10 for portability");
1940*fd82c4c4Schristos # endif
1941*fd82c4c4Schristos #endif
1942*fd82c4c4Schristos 
1943*fd82c4c4Schristos #if 0
1944*fd82c4c4Schristos # if 0
1945*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1946*fd82c4c4Schristos #   undef log10l
1947*fd82c4c4Schristos #   define log10l rpl_log10l
1948*fd82c4c4Schristos #  endif
1949*fd82c4c4Schristos _GL_FUNCDECL_RPL (log10l, long double, (long double x));
1950*fd82c4c4Schristos _GL_CXXALIAS_RPL (log10l, long double, (long double x));
1951*fd82c4c4Schristos # else
1952*fd82c4c4Schristos #  if !1 || !1
1953*fd82c4c4Schristos #   undef log10l
1954*fd82c4c4Schristos _GL_FUNCDECL_SYS (log10l, long double, (long double x));
1955*fd82c4c4Schristos #  endif
1956*fd82c4c4Schristos _GL_CXXALIAS_SYS (log10l, long double, (long double x));
1957*fd82c4c4Schristos # endif
1958*fd82c4c4Schristos _GL_CXXALIASWARN (log10l);
1959*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1960*fd82c4c4Schristos # undef log10l
1961*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG10L
1962*fd82c4c4Schristos _GL_WARN_ON_USE (log10l, "log10l is unportable - "
1963*fd82c4c4Schristos                  "use gnulib module log10l for portability");
1964*fd82c4c4Schristos # endif
1965*fd82c4c4Schristos #endif
1966*fd82c4c4Schristos 
1967*fd82c4c4Schristos 
1968*fd82c4c4Schristos #if 0
1969*fd82c4c4Schristos # if 0
1970*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1971*fd82c4c4Schristos #   undef log1pf
1972*fd82c4c4Schristos #   define log1pf rpl_log1pf
1973*fd82c4c4Schristos #  endif
1974*fd82c4c4Schristos _GL_FUNCDECL_RPL (log1pf, float, (float x));
1975*fd82c4c4Schristos _GL_CXXALIAS_RPL (log1pf, float, (float x));
1976*fd82c4c4Schristos # else
1977*fd82c4c4Schristos #  if !1
1978*fd82c4c4Schristos _GL_FUNCDECL_SYS (log1pf, float, (float x));
1979*fd82c4c4Schristos #  endif
1980*fd82c4c4Schristos _GL_CXXALIAS_SYS (log1pf, float, (float x));
1981*fd82c4c4Schristos # endif
1982*fd82c4c4Schristos _GL_CXXALIASWARN (log1pf);
1983*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
1984*fd82c4c4Schristos # undef log1pf
1985*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG1PF
1986*fd82c4c4Schristos _GL_WARN_ON_USE (log1pf, "log1pf is unportable - "
1987*fd82c4c4Schristos                  "use gnulib module log1pf for portability");
1988*fd82c4c4Schristos # endif
1989*fd82c4c4Schristos #endif
1990*fd82c4c4Schristos 
1991*fd82c4c4Schristos #if 0
1992*fd82c4c4Schristos # if 0
1993*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1994*fd82c4c4Schristos #   undef log1p
1995*fd82c4c4Schristos #   define log1p rpl_log1p
1996*fd82c4c4Schristos #  endif
1997*fd82c4c4Schristos _GL_FUNCDECL_RPL (log1p, double, (double x));
1998*fd82c4c4Schristos _GL_CXXALIAS_RPL (log1p, double, (double x));
1999*fd82c4c4Schristos # else
2000*fd82c4c4Schristos #  if !1
2001*fd82c4c4Schristos _GL_FUNCDECL_SYS (log1p, double, (double x));
2002*fd82c4c4Schristos #  endif
2003*fd82c4c4Schristos _GL_CXXALIAS_SYS (log1p, double, (double x));
2004*fd82c4c4Schristos # endif
2005*fd82c4c4Schristos # if __GLIBC__ >= 2
2006*fd82c4c4Schristos _GL_CXXALIASWARN (log1p);
2007*fd82c4c4Schristos # endif
2008*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2009*fd82c4c4Schristos # undef log1p
2010*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG1P
2011*fd82c4c4Schristos _GL_WARN_ON_USE (log1p, "log1p has portability problems - "
2012*fd82c4c4Schristos                  "use gnulib module log1p for portability");
2013*fd82c4c4Schristos # endif
2014*fd82c4c4Schristos #endif
2015*fd82c4c4Schristos 
2016*fd82c4c4Schristos #if 0
2017*fd82c4c4Schristos # if 0
2018*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2019*fd82c4c4Schristos #   undef log1pl
2020*fd82c4c4Schristos #   define log1pl rpl_log1pl
2021*fd82c4c4Schristos #  endif
2022*fd82c4c4Schristos _GL_FUNCDECL_RPL (log1pl, long double, (long double x));
2023*fd82c4c4Schristos _GL_CXXALIAS_RPL (log1pl, long double, (long double x));
2024*fd82c4c4Schristos # else
2025*fd82c4c4Schristos #  if !1
2026*fd82c4c4Schristos _GL_FUNCDECL_SYS (log1pl, long double, (long double x));
2027*fd82c4c4Schristos #  endif
2028*fd82c4c4Schristos _GL_CXXALIAS_SYS (log1pl, long double, (long double x));
2029*fd82c4c4Schristos # endif
2030*fd82c4c4Schristos _GL_CXXALIASWARN (log1pl);
2031*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2032*fd82c4c4Schristos # undef log1pl
2033*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG1PL
2034*fd82c4c4Schristos _GL_WARN_ON_USE (log1pl, "log1pl has portability problems - "
2035*fd82c4c4Schristos                  "use gnulib module log1pl for portability");
2036*fd82c4c4Schristos # endif
2037*fd82c4c4Schristos #endif
2038*fd82c4c4Schristos 
2039*fd82c4c4Schristos 
2040*fd82c4c4Schristos #if 0
2041*fd82c4c4Schristos # if 0
2042*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2043*fd82c4c4Schristos #   undef log2f
2044*fd82c4c4Schristos #   define log2f rpl_log2f
2045*fd82c4c4Schristos #  endif
2046*fd82c4c4Schristos _GL_FUNCDECL_RPL (log2f, float, (float x));
2047*fd82c4c4Schristos _GL_CXXALIAS_RPL (log2f, float, (float x));
2048*fd82c4c4Schristos # else
2049*fd82c4c4Schristos #  if !1
2050*fd82c4c4Schristos #   undef log2f
2051*fd82c4c4Schristos _GL_FUNCDECL_SYS (log2f, float, (float x));
2052*fd82c4c4Schristos #  endif
2053*fd82c4c4Schristos _GL_CXXALIAS_SYS (log2f, float, (float x));
2054*fd82c4c4Schristos # endif
2055*fd82c4c4Schristos _GL_CXXALIASWARN (log2f);
2056*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2057*fd82c4c4Schristos # undef log2f
2058*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG2F
2059*fd82c4c4Schristos _GL_WARN_ON_USE (log2f, "log2f is unportable - "
2060*fd82c4c4Schristos                  "use gnulib module log2f for portability");
2061*fd82c4c4Schristos # endif
2062*fd82c4c4Schristos #endif
2063*fd82c4c4Schristos 
2064*fd82c4c4Schristos #if 0
2065*fd82c4c4Schristos # if 0
2066*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2067*fd82c4c4Schristos #   undef log2
2068*fd82c4c4Schristos #   define log2 rpl_log2
2069*fd82c4c4Schristos #  endif
2070*fd82c4c4Schristos _GL_FUNCDECL_RPL (log2, double, (double x));
2071*fd82c4c4Schristos _GL_CXXALIAS_RPL (log2, double, (double x));
2072*fd82c4c4Schristos # else
2073*fd82c4c4Schristos #  if !1
2074*fd82c4c4Schristos #   undef log2
2075*fd82c4c4Schristos _GL_FUNCDECL_SYS (log2, double, (double x));
2076*fd82c4c4Schristos #  endif
2077*fd82c4c4Schristos _GL_CXXALIAS_SYS (log2, double, (double x));
2078*fd82c4c4Schristos # endif
2079*fd82c4c4Schristos # if __GLIBC__ >= 2
2080*fd82c4c4Schristos _GL_CXXALIASWARN (log2);
2081*fd82c4c4Schristos # endif
2082*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2083*fd82c4c4Schristos # undef log2
2084*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG2
2085*fd82c4c4Schristos _GL_WARN_ON_USE (log2, "log2 is unportable - "
2086*fd82c4c4Schristos                  "use gnulib module log2 for portability");
2087*fd82c4c4Schristos # endif
2088*fd82c4c4Schristos #endif
2089*fd82c4c4Schristos 
2090*fd82c4c4Schristos #if 0
2091*fd82c4c4Schristos # if 0
2092*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2093*fd82c4c4Schristos #   undef log2l
2094*fd82c4c4Schristos #   define log2l rpl_log2l
2095*fd82c4c4Schristos #  endif
2096*fd82c4c4Schristos _GL_FUNCDECL_RPL (log2l, long double, (long double x));
2097*fd82c4c4Schristos _GL_CXXALIAS_RPL (log2l, long double, (long double x));
2098*fd82c4c4Schristos # else
2099*fd82c4c4Schristos #  if !1
2100*fd82c4c4Schristos _GL_FUNCDECL_SYS (log2l, long double, (long double x));
2101*fd82c4c4Schristos #  endif
2102*fd82c4c4Schristos _GL_CXXALIAS_SYS (log2l, long double, (long double x));
2103*fd82c4c4Schristos # endif
2104*fd82c4c4Schristos _GL_CXXALIASWARN (log2l);
2105*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2106*fd82c4c4Schristos # undef log2l
2107*fd82c4c4Schristos # if HAVE_RAW_DECL_LOG2L
2108*fd82c4c4Schristos _GL_WARN_ON_USE (log2l, "log2l is unportable - "
2109*fd82c4c4Schristos                  "use gnulib module log2l for portability");
2110*fd82c4c4Schristos # endif
2111*fd82c4c4Schristos #endif
2112*fd82c4c4Schristos 
2113*fd82c4c4Schristos 
2114*fd82c4c4Schristos #if 0
2115*fd82c4c4Schristos # if 0
2116*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2117*fd82c4c4Schristos #   undef logbf
2118*fd82c4c4Schristos #   define logbf rpl_logbf
2119*fd82c4c4Schristos #  endif
2120*fd82c4c4Schristos _GL_FUNCDECL_RPL (logbf, float, (float x));
2121*fd82c4c4Schristos _GL_CXXALIAS_RPL (logbf, float, (float x));
2122*fd82c4c4Schristos # else
2123*fd82c4c4Schristos #  if !1
2124*fd82c4c4Schristos _GL_FUNCDECL_SYS (logbf, float, (float x));
2125*fd82c4c4Schristos #  endif
2126*fd82c4c4Schristos _GL_CXXALIAS_SYS (logbf, float, (float x));
2127*fd82c4c4Schristos # endif
2128*fd82c4c4Schristos _GL_CXXALIASWARN (logbf);
2129*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2130*fd82c4c4Schristos # undef logbf
2131*fd82c4c4Schristos # if HAVE_RAW_DECL_LOGBF
2132*fd82c4c4Schristos _GL_WARN_ON_USE (logbf, "logbf is unportable - "
2133*fd82c4c4Schristos                  "use gnulib module logbf for portability");
2134*fd82c4c4Schristos # endif
2135*fd82c4c4Schristos #endif
2136*fd82c4c4Schristos 
2137*fd82c4c4Schristos #if 0
2138*fd82c4c4Schristos # if 0
2139*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2140*fd82c4c4Schristos #   undef logb
2141*fd82c4c4Schristos #   define logb rpl_logb
2142*fd82c4c4Schristos #  endif
2143*fd82c4c4Schristos _GL_FUNCDECL_RPL (logb, double, (double x));
2144*fd82c4c4Schristos _GL_CXXALIAS_RPL (logb, double, (double x));
2145*fd82c4c4Schristos # else
2146*fd82c4c4Schristos #  if !1
2147*fd82c4c4Schristos _GL_FUNCDECL_SYS (logb, double, (double x));
2148*fd82c4c4Schristos #  endif
2149*fd82c4c4Schristos _GL_CXXALIAS_SYS (logb, double, (double x));
2150*fd82c4c4Schristos # endif
2151*fd82c4c4Schristos # if __GLIBC__ >= 2
2152*fd82c4c4Schristos _GL_CXXALIASWARN (logb);
2153*fd82c4c4Schristos # endif
2154*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2155*fd82c4c4Schristos # undef logb
2156*fd82c4c4Schristos # if HAVE_RAW_DECL_LOGB
2157*fd82c4c4Schristos _GL_WARN_ON_USE (logb, "logb is unportable - "
2158*fd82c4c4Schristos                  "use gnulib module logb for portability");
2159*fd82c4c4Schristos # endif
2160*fd82c4c4Schristos #endif
2161*fd82c4c4Schristos 
2162*fd82c4c4Schristos #if 0
2163*fd82c4c4Schristos # if 0
2164*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2165*fd82c4c4Schristos #   undef logbl
2166*fd82c4c4Schristos #   define logbl rpl_logbl
2167*fd82c4c4Schristos #  endif
2168*fd82c4c4Schristos _GL_FUNCDECL_RPL (logbl, long double, (long double x));
2169*fd82c4c4Schristos _GL_CXXALIAS_RPL (logbl, long double, (long double x));
2170*fd82c4c4Schristos # else
2171*fd82c4c4Schristos #  if !1
2172*fd82c4c4Schristos _GL_FUNCDECL_SYS (logbl, long double, (long double x));
2173*fd82c4c4Schristos #  endif
2174*fd82c4c4Schristos _GL_CXXALIAS_SYS (logbl, long double, (long double x));
2175*fd82c4c4Schristos # endif
2176*fd82c4c4Schristos _GL_CXXALIASWARN (logbl);
2177*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2178*fd82c4c4Schristos # undef logbl
2179*fd82c4c4Schristos # if HAVE_RAW_DECL_LOGBL
2180*fd82c4c4Schristos _GL_WARN_ON_USE (logbl, "logbl is unportable - "
2181*fd82c4c4Schristos                  "use gnulib module logbl for portability");
2182*fd82c4c4Schristos # endif
2183*fd82c4c4Schristos #endif
2184*fd82c4c4Schristos 
2185*fd82c4c4Schristos 
2186*fd82c4c4Schristos #if 0
2187*fd82c4c4Schristos # if 0
2188*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2189*fd82c4c4Schristos #   undef modff
2190*fd82c4c4Schristos #   define modff rpl_modff
2191*fd82c4c4Schristos #  endif
2192*fd82c4c4Schristos _GL_FUNCDECL_RPL (modff, float, (float x, float *iptr) _GL_ARG_NONNULL ((2)));
2193*fd82c4c4Schristos _GL_CXXALIAS_RPL (modff, float, (float x, float *iptr));
2194*fd82c4c4Schristos # else
2195*fd82c4c4Schristos #  if !1
2196*fd82c4c4Schristos #   undef modff
2197*fd82c4c4Schristos _GL_FUNCDECL_SYS (modff, float, (float x, float *iptr) _GL_ARG_NONNULL ((2)));
2198*fd82c4c4Schristos #  endif
2199*fd82c4c4Schristos _GL_CXXALIAS_SYS (modff, float, (float x, float *iptr));
2200*fd82c4c4Schristos # endif
2201*fd82c4c4Schristos _GL_CXXALIASWARN (modff);
2202*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2203*fd82c4c4Schristos # undef modff
2204*fd82c4c4Schristos # if HAVE_RAW_DECL_MODFF
2205*fd82c4c4Schristos _GL_WARN_ON_USE (modff, "modff is unportable - "
2206*fd82c4c4Schristos                  "use gnulib module modff for portability");
2207*fd82c4c4Schristos # endif
2208*fd82c4c4Schristos #endif
2209*fd82c4c4Schristos 
2210*fd82c4c4Schristos #if 0
2211*fd82c4c4Schristos # if 0
2212*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2213*fd82c4c4Schristos #   undef modf
2214*fd82c4c4Schristos #   define modf rpl_modf
2215*fd82c4c4Schristos #  endif
2216*fd82c4c4Schristos _GL_FUNCDECL_RPL (modf, double, (double x, double *iptr) _GL_ARG_NONNULL ((2)));
2217*fd82c4c4Schristos _GL_CXXALIAS_RPL (modf, double, (double x, double *iptr));
2218*fd82c4c4Schristos # else
2219*fd82c4c4Schristos _GL_CXXALIAS_SYS (modf, double, (double x, double *iptr));
2220*fd82c4c4Schristos # endif
2221*fd82c4c4Schristos # if __GLIBC__ >= 2
2222*fd82c4c4Schristos _GL_CXXALIASWARN (modf);
2223*fd82c4c4Schristos # endif
2224*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2225*fd82c4c4Schristos # undef modf
2226*fd82c4c4Schristos # if HAVE_RAW_DECL_MODF
2227*fd82c4c4Schristos _GL_WARN_ON_USE (modf, "modf has portability problems - "
2228*fd82c4c4Schristos                  "use gnulib module modf for portability");
2229*fd82c4c4Schristos # endif
2230*fd82c4c4Schristos #endif
2231*fd82c4c4Schristos 
2232*fd82c4c4Schristos #if 0
2233*fd82c4c4Schristos # if 0
2234*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2235*fd82c4c4Schristos #   undef modfl
2236*fd82c4c4Schristos #   define modfl rpl_modfl
2237*fd82c4c4Schristos #  endif
2238*fd82c4c4Schristos _GL_FUNCDECL_RPL (modfl, long double, (long double x, long double *iptr)
2239*fd82c4c4Schristos                                       _GL_ARG_NONNULL ((2)));
2240*fd82c4c4Schristos _GL_CXXALIAS_RPL (modfl, long double, (long double x, long double *iptr));
2241*fd82c4c4Schristos # else
2242*fd82c4c4Schristos #  if !1
2243*fd82c4c4Schristos #   undef modfl
2244*fd82c4c4Schristos _GL_FUNCDECL_SYS (modfl, long double, (long double x, long double *iptr)
2245*fd82c4c4Schristos                                       _GL_ARG_NONNULL ((2)));
2246*fd82c4c4Schristos #  endif
2247*fd82c4c4Schristos _GL_CXXALIAS_SYS (modfl, long double, (long double x, long double *iptr));
2248*fd82c4c4Schristos # endif
2249*fd82c4c4Schristos _GL_CXXALIASWARN (modfl);
2250*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2251*fd82c4c4Schristos # undef modfl
2252*fd82c4c4Schristos # if HAVE_RAW_DECL_MODFL
2253*fd82c4c4Schristos _GL_WARN_ON_USE (modfl, "modfl is unportable - "
2254*fd82c4c4Schristos                  "use gnulib module modfl for portability");
2255*fd82c4c4Schristos # endif
2256*fd82c4c4Schristos #endif
2257*fd82c4c4Schristos 
2258*fd82c4c4Schristos 
2259*fd82c4c4Schristos #if 0
2260*fd82c4c4Schristos # if !1
2261*fd82c4c4Schristos #  undef powf
2262*fd82c4c4Schristos _GL_FUNCDECL_SYS (powf, float, (float x, float y));
2263*fd82c4c4Schristos # endif
2264*fd82c4c4Schristos _GL_CXXALIAS_SYS (powf, float, (float x, float y));
2265*fd82c4c4Schristos _GL_CXXALIASWARN (powf);
2266*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2267*fd82c4c4Schristos # undef powf
2268*fd82c4c4Schristos # if HAVE_RAW_DECL_POWF
2269*fd82c4c4Schristos _GL_WARN_ON_USE (powf, "powf is unportable - "
2270*fd82c4c4Schristos                  "use gnulib module powf for portability");
2271*fd82c4c4Schristos # endif
2272*fd82c4c4Schristos #endif
2273*fd82c4c4Schristos 
2274*fd82c4c4Schristos 
2275*fd82c4c4Schristos #if 0
2276*fd82c4c4Schristos # if 0
2277*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2278*fd82c4c4Schristos #   undef remainderf
2279*fd82c4c4Schristos #   define remainderf rpl_remainderf
2280*fd82c4c4Schristos #  endif
2281*fd82c4c4Schristos _GL_FUNCDECL_RPL (remainderf, float, (float x, float y));
2282*fd82c4c4Schristos _GL_CXXALIAS_RPL (remainderf, float, (float x, float y));
2283*fd82c4c4Schristos # else
2284*fd82c4c4Schristos #  if !1
2285*fd82c4c4Schristos _GL_FUNCDECL_SYS (remainderf, float, (float x, float y));
2286*fd82c4c4Schristos #  endif
2287*fd82c4c4Schristos _GL_CXXALIAS_SYS (remainderf, float, (float x, float y));
2288*fd82c4c4Schristos # endif
2289*fd82c4c4Schristos _GL_CXXALIASWARN (remainderf);
2290*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2291*fd82c4c4Schristos # undef remainderf
2292*fd82c4c4Schristos # if HAVE_RAW_DECL_REMAINDERF
2293*fd82c4c4Schristos _GL_WARN_ON_USE (remainderf, "remainderf is unportable - "
2294*fd82c4c4Schristos                  "use gnulib module remainderf for portability");
2295*fd82c4c4Schristos # endif
2296*fd82c4c4Schristos #endif
2297*fd82c4c4Schristos 
2298*fd82c4c4Schristos #if 0
2299*fd82c4c4Schristos # if 0
2300*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2301*fd82c4c4Schristos #   undef remainder
2302*fd82c4c4Schristos #   define remainder rpl_remainder
2303*fd82c4c4Schristos #  endif
2304*fd82c4c4Schristos _GL_FUNCDECL_RPL (remainder, double, (double x, double y));
2305*fd82c4c4Schristos _GL_CXXALIAS_RPL (remainder, double, (double x, double y));
2306*fd82c4c4Schristos # else
2307*fd82c4c4Schristos #  if !1 || !1
2308*fd82c4c4Schristos _GL_FUNCDECL_SYS (remainder, double, (double x, double y));
2309*fd82c4c4Schristos #  endif
2310*fd82c4c4Schristos _GL_CXXALIAS_SYS (remainder, double, (double x, double y));
2311*fd82c4c4Schristos # endif
2312*fd82c4c4Schristos # if __GLIBC__ >= 2
2313*fd82c4c4Schristos _GL_CXXALIASWARN (remainder);
2314*fd82c4c4Schristos # endif
2315*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2316*fd82c4c4Schristos # undef remainder
2317*fd82c4c4Schristos # if HAVE_RAW_DECL_REMAINDER
2318*fd82c4c4Schristos _GL_WARN_ON_USE (remainder, "remainder is unportable - "
2319*fd82c4c4Schristos                  "use gnulib module remainder for portability");
2320*fd82c4c4Schristos # endif
2321*fd82c4c4Schristos #endif
2322*fd82c4c4Schristos 
2323*fd82c4c4Schristos #if 0
2324*fd82c4c4Schristos # if 0
2325*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2326*fd82c4c4Schristos #   undef remainderl
2327*fd82c4c4Schristos #   define remainderl rpl_remainderl
2328*fd82c4c4Schristos #  endif
2329*fd82c4c4Schristos _GL_FUNCDECL_RPL (remainderl, long double, (long double x, long double y));
2330*fd82c4c4Schristos _GL_CXXALIAS_RPL (remainderl, long double, (long double x, long double y));
2331*fd82c4c4Schristos # else
2332*fd82c4c4Schristos #  if !1
2333*fd82c4c4Schristos #   undef remainderl
2334*fd82c4c4Schristos #   if !(defined __cplusplus && defined _AIX)
2335*fd82c4c4Schristos _GL_FUNCDECL_SYS (remainderl, long double, (long double x, long double y));
2336*fd82c4c4Schristos #   endif
2337*fd82c4c4Schristos #  endif
2338*fd82c4c4Schristos _GL_CXXALIAS_SYS (remainderl, long double, (long double x, long double y));
2339*fd82c4c4Schristos # endif
2340*fd82c4c4Schristos _GL_CXXALIASWARN (remainderl);
2341*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2342*fd82c4c4Schristos # undef remainderl
2343*fd82c4c4Schristos # if HAVE_RAW_DECL_REMAINDERL
2344*fd82c4c4Schristos _GL_WARN_ON_USE (remainderl, "remainderl is unportable - "
2345*fd82c4c4Schristos                  "use gnulib module remainderl for portability");
2346*fd82c4c4Schristos # endif
2347*fd82c4c4Schristos #endif
2348*fd82c4c4Schristos 
2349*fd82c4c4Schristos 
2350*fd82c4c4Schristos #if 0
2351*fd82c4c4Schristos # if !1
2352*fd82c4c4Schristos _GL_FUNCDECL_SYS (rintf, float, (float x));
2353*fd82c4c4Schristos # endif
2354*fd82c4c4Schristos _GL_CXXALIAS_SYS (rintf, float, (float x));
2355*fd82c4c4Schristos _GL_CXXALIASWARN (rintf);
2356*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2357*fd82c4c4Schristos # undef rintf
2358*fd82c4c4Schristos # if HAVE_RAW_DECL_RINTF
2359*fd82c4c4Schristos _GL_WARN_ON_USE (rintf, "rintf is unportable - "
2360*fd82c4c4Schristos                  "use gnulib module rintf for portability");
2361*fd82c4c4Schristos # endif
2362*fd82c4c4Schristos #endif
2363*fd82c4c4Schristos 
2364*fd82c4c4Schristos #if 0
2365*fd82c4c4Schristos # if !1
2366*fd82c4c4Schristos _GL_FUNCDECL_SYS (rint, double, (double x));
2367*fd82c4c4Schristos # endif
2368*fd82c4c4Schristos _GL_CXXALIAS_SYS (rint, double, (double x));
2369*fd82c4c4Schristos # if __GLIBC__ >= 2
2370*fd82c4c4Schristos _GL_CXXALIASWARN (rint);
2371*fd82c4c4Schristos # endif
2372*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2373*fd82c4c4Schristos # undef rint
2374*fd82c4c4Schristos # if HAVE_RAW_DECL_RINT
2375*fd82c4c4Schristos _GL_WARN_ON_USE (rint, "rint is unportable - "
2376*fd82c4c4Schristos                  "use gnulib module rint for portability");
2377*fd82c4c4Schristos # endif
2378*fd82c4c4Schristos #endif
2379*fd82c4c4Schristos 
2380*fd82c4c4Schristos #if 0
2381*fd82c4c4Schristos # if 0
2382*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2383*fd82c4c4Schristos #   undef rintl
2384*fd82c4c4Schristos #   define rintl rpl_rintl
2385*fd82c4c4Schristos #  endif
2386*fd82c4c4Schristos _GL_FUNCDECL_RPL (rintl, long double, (long double x));
2387*fd82c4c4Schristos _GL_CXXALIAS_RPL (rintl, long double, (long double x));
2388*fd82c4c4Schristos # else
2389*fd82c4c4Schristos #  if !1
2390*fd82c4c4Schristos _GL_FUNCDECL_SYS (rintl, long double, (long double x));
2391*fd82c4c4Schristos #  endif
2392*fd82c4c4Schristos _GL_CXXALIAS_SYS (rintl, long double, (long double x));
2393*fd82c4c4Schristos # endif
2394*fd82c4c4Schristos _GL_CXXALIASWARN (rintl);
2395*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2396*fd82c4c4Schristos # undef rintl
2397*fd82c4c4Schristos # if HAVE_RAW_DECL_RINTL
2398*fd82c4c4Schristos _GL_WARN_ON_USE (rintl, "rintl is unportable - "
2399*fd82c4c4Schristos                  "use gnulib module rintl for portability");
2400*fd82c4c4Schristos # endif
2401*fd82c4c4Schristos #endif
2402*fd82c4c4Schristos 
2403*fd82c4c4Schristos 
2404*fd82c4c4Schristos #if 0
2405*fd82c4c4Schristos # if 0
2406*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2407*fd82c4c4Schristos #   undef roundf
2408*fd82c4c4Schristos #   define roundf rpl_roundf
2409*fd82c4c4Schristos #  endif
2410*fd82c4c4Schristos _GL_FUNCDECL_RPL (roundf, float, (float x));
2411*fd82c4c4Schristos _GL_CXXALIAS_RPL (roundf, float, (float x));
2412*fd82c4c4Schristos # else
2413*fd82c4c4Schristos #  if !1
2414*fd82c4c4Schristos _GL_FUNCDECL_SYS (roundf, float, (float x));
2415*fd82c4c4Schristos #  endif
2416*fd82c4c4Schristos _GL_CXXALIAS_SYS (roundf, float, (float x));
2417*fd82c4c4Schristos # endif
2418*fd82c4c4Schristos _GL_CXXALIASWARN (roundf);
2419*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2420*fd82c4c4Schristos # undef roundf
2421*fd82c4c4Schristos # if HAVE_RAW_DECL_ROUNDF
2422*fd82c4c4Schristos _GL_WARN_ON_USE (roundf, "roundf is unportable - "
2423*fd82c4c4Schristos                  "use gnulib module roundf for portability");
2424*fd82c4c4Schristos # endif
2425*fd82c4c4Schristos #endif
2426*fd82c4c4Schristos 
2427*fd82c4c4Schristos #if 0
2428*fd82c4c4Schristos # if 0
2429*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2430*fd82c4c4Schristos #   undef round
2431*fd82c4c4Schristos #   define round rpl_round
2432*fd82c4c4Schristos #  endif
2433*fd82c4c4Schristos _GL_FUNCDECL_RPL (round, double, (double x));
2434*fd82c4c4Schristos _GL_CXXALIAS_RPL (round, double, (double x));
2435*fd82c4c4Schristos # else
2436*fd82c4c4Schristos #  if !1
2437*fd82c4c4Schristos _GL_FUNCDECL_SYS (round, double, (double x));
2438*fd82c4c4Schristos #  endif
2439*fd82c4c4Schristos _GL_CXXALIAS_SYS (round, double, (double x));
2440*fd82c4c4Schristos # endif
2441*fd82c4c4Schristos # if __GLIBC__ >= 2
2442*fd82c4c4Schristos _GL_CXXALIASWARN (round);
2443*fd82c4c4Schristos # endif
2444*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2445*fd82c4c4Schristos # undef round
2446*fd82c4c4Schristos # if HAVE_RAW_DECL_ROUND
2447*fd82c4c4Schristos _GL_WARN_ON_USE (round, "round is unportable - "
2448*fd82c4c4Schristos                  "use gnulib module round for portability");
2449*fd82c4c4Schristos # endif
2450*fd82c4c4Schristos #endif
2451*fd82c4c4Schristos 
2452*fd82c4c4Schristos #if 0
2453*fd82c4c4Schristos # if 0
2454*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2455*fd82c4c4Schristos #   undef roundl
2456*fd82c4c4Schristos #   define roundl rpl_roundl
2457*fd82c4c4Schristos #  endif
2458*fd82c4c4Schristos _GL_FUNCDECL_RPL (roundl, long double, (long double x));
2459*fd82c4c4Schristos _GL_CXXALIAS_RPL (roundl, long double, (long double x));
2460*fd82c4c4Schristos # else
2461*fd82c4c4Schristos #  if !1
2462*fd82c4c4Schristos #   undef roundl
2463*fd82c4c4Schristos #   if !(defined __cplusplus && defined _AIX)
2464*fd82c4c4Schristos _GL_FUNCDECL_SYS (roundl, long double, (long double x));
2465*fd82c4c4Schristos #   endif
2466*fd82c4c4Schristos #  endif
2467*fd82c4c4Schristos _GL_CXXALIAS_SYS (roundl, long double, (long double x));
2468*fd82c4c4Schristos # endif
2469*fd82c4c4Schristos _GL_CXXALIASWARN (roundl);
2470*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2471*fd82c4c4Schristos # undef roundl
2472*fd82c4c4Schristos # if HAVE_RAW_DECL_ROUNDL
2473*fd82c4c4Schristos _GL_WARN_ON_USE (roundl, "roundl is unportable - "
2474*fd82c4c4Schristos                  "use gnulib module roundl for portability");
2475*fd82c4c4Schristos # endif
2476*fd82c4c4Schristos #endif
2477*fd82c4c4Schristos 
2478*fd82c4c4Schristos 
2479*fd82c4c4Schristos #if 0
2480*fd82c4c4Schristos # if 0
2481*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2482*fd82c4c4Schristos #   undef sinf
2483*fd82c4c4Schristos #   define sinf rpl_sinf
2484*fd82c4c4Schristos #  endif
2485*fd82c4c4Schristos _GL_FUNCDECL_RPL (sinf, float, (float x));
2486*fd82c4c4Schristos _GL_CXXALIAS_RPL (sinf, float, (float x));
2487*fd82c4c4Schristos # else
2488*fd82c4c4Schristos #  if !1
2489*fd82c4c4Schristos  #  undef sinf
2490*fd82c4c4Schristos _GL_FUNCDECL_SYS (sinf, float, (float x));
2491*fd82c4c4Schristos #  endif
2492*fd82c4c4Schristos _GL_CXXALIAS_SYS (sinf, float, (float x));
2493*fd82c4c4Schristos # endif
2494*fd82c4c4Schristos _GL_CXXALIASWARN (sinf);
2495*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2496*fd82c4c4Schristos # undef sinf
2497*fd82c4c4Schristos # if HAVE_RAW_DECL_SINF
2498*fd82c4c4Schristos _GL_WARN_ON_USE (sinf, "sinf is unportable - "
2499*fd82c4c4Schristos                  "use gnulib module sinf for portability");
2500*fd82c4c4Schristos # endif
2501*fd82c4c4Schristos #endif
2502*fd82c4c4Schristos 
2503*fd82c4c4Schristos #if 0
2504*fd82c4c4Schristos # if !1 || !1
2505*fd82c4c4Schristos #  undef sinl
2506*fd82c4c4Schristos _GL_FUNCDECL_SYS (sinl, long double, (long double x));
2507*fd82c4c4Schristos # endif
2508*fd82c4c4Schristos _GL_CXXALIAS_SYS (sinl, long double, (long double x));
2509*fd82c4c4Schristos _GL_CXXALIASWARN (sinl);
2510*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2511*fd82c4c4Schristos # undef sinl
2512*fd82c4c4Schristos # if HAVE_RAW_DECL_SINL
2513*fd82c4c4Schristos _GL_WARN_ON_USE (sinl, "sinl is unportable - "
2514*fd82c4c4Schristos                  "use gnulib module sinl for portability");
2515*fd82c4c4Schristos # endif
2516*fd82c4c4Schristos #endif
2517*fd82c4c4Schristos 
2518*fd82c4c4Schristos 
2519*fd82c4c4Schristos #if 0
2520*fd82c4c4Schristos # if 0
2521*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2522*fd82c4c4Schristos #   undef sinhf
2523*fd82c4c4Schristos #   define sinhf rpl_sinhf
2524*fd82c4c4Schristos #  endif
2525*fd82c4c4Schristos _GL_FUNCDECL_RPL (sinhf, float, (float x));
2526*fd82c4c4Schristos _GL_CXXALIAS_RPL (sinhf, float, (float x));
2527*fd82c4c4Schristos # else
2528*fd82c4c4Schristos #  if !1
2529*fd82c4c4Schristos #   undef sinhf
2530*fd82c4c4Schristos _GL_FUNCDECL_SYS (sinhf, float, (float x));
2531*fd82c4c4Schristos #  endif
2532*fd82c4c4Schristos _GL_CXXALIAS_SYS (sinhf, float, (float x));
2533*fd82c4c4Schristos # endif
2534*fd82c4c4Schristos _GL_CXXALIASWARN (sinhf);
2535*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2536*fd82c4c4Schristos # undef sinhf
2537*fd82c4c4Schristos # if HAVE_RAW_DECL_SINHF
2538*fd82c4c4Schristos _GL_WARN_ON_USE (sinhf, "sinhf is unportable - "
2539*fd82c4c4Schristos                  "use gnulib module sinhf for portability");
2540*fd82c4c4Schristos # endif
2541*fd82c4c4Schristos #endif
2542*fd82c4c4Schristos 
2543*fd82c4c4Schristos 
2544*fd82c4c4Schristos #if 0
2545*fd82c4c4Schristos # if 0
2546*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2547*fd82c4c4Schristos #   undef sqrtf
2548*fd82c4c4Schristos #   define sqrtf rpl_sqrtf
2549*fd82c4c4Schristos #  endif
2550*fd82c4c4Schristos _GL_FUNCDECL_RPL (sqrtf, float, (float x));
2551*fd82c4c4Schristos _GL_CXXALIAS_RPL (sqrtf, float, (float x));
2552*fd82c4c4Schristos # else
2553*fd82c4c4Schristos #  if !1
2554*fd82c4c4Schristos #   undef sqrtf
2555*fd82c4c4Schristos _GL_FUNCDECL_SYS (sqrtf, float, (float x));
2556*fd82c4c4Schristos #  endif
2557*fd82c4c4Schristos _GL_CXXALIAS_SYS (sqrtf, float, (float x));
2558*fd82c4c4Schristos # endif
2559*fd82c4c4Schristos _GL_CXXALIASWARN (sqrtf);
2560*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2561*fd82c4c4Schristos # undef sqrtf
2562*fd82c4c4Schristos # if HAVE_RAW_DECL_SQRTF
2563*fd82c4c4Schristos _GL_WARN_ON_USE (sqrtf, "sqrtf is unportable - "
2564*fd82c4c4Schristos                  "use gnulib module sqrtf for portability");
2565*fd82c4c4Schristos # endif
2566*fd82c4c4Schristos #endif
2567*fd82c4c4Schristos 
2568*fd82c4c4Schristos #if 0
2569*fd82c4c4Schristos # if 0
2570*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2571*fd82c4c4Schristos #   undef sqrtl
2572*fd82c4c4Schristos #   define sqrtl rpl_sqrtl
2573*fd82c4c4Schristos #  endif
2574*fd82c4c4Schristos _GL_FUNCDECL_RPL (sqrtl, long double, (long double x));
2575*fd82c4c4Schristos _GL_CXXALIAS_RPL (sqrtl, long double, (long double x));
2576*fd82c4c4Schristos # else
2577*fd82c4c4Schristos #  if !1 || !1
2578*fd82c4c4Schristos #   undef sqrtl
2579*fd82c4c4Schristos _GL_FUNCDECL_SYS (sqrtl, long double, (long double x));
2580*fd82c4c4Schristos #  endif
2581*fd82c4c4Schristos _GL_CXXALIAS_SYS (sqrtl, long double, (long double x));
2582*fd82c4c4Schristos # endif
2583*fd82c4c4Schristos _GL_CXXALIASWARN (sqrtl);
2584*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2585*fd82c4c4Schristos # undef sqrtl
2586*fd82c4c4Schristos # if HAVE_RAW_DECL_SQRTL
2587*fd82c4c4Schristos _GL_WARN_ON_USE (sqrtl, "sqrtl is unportable - "
2588*fd82c4c4Schristos                  "use gnulib module sqrtl for portability");
2589*fd82c4c4Schristos # endif
2590*fd82c4c4Schristos #endif
2591*fd82c4c4Schristos 
2592*fd82c4c4Schristos 
2593*fd82c4c4Schristos #if 0
2594*fd82c4c4Schristos # if 0
2595*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2596*fd82c4c4Schristos #   undef tanf
2597*fd82c4c4Schristos #   define tanf rpl_tanf
2598*fd82c4c4Schristos #  endif
2599*fd82c4c4Schristos _GL_FUNCDECL_RPL (tanf, float, (float x));
2600*fd82c4c4Schristos _GL_CXXALIAS_RPL (tanf, float, (float x));
2601*fd82c4c4Schristos # else
2602*fd82c4c4Schristos #  if !1
2603*fd82c4c4Schristos #   undef tanf
2604*fd82c4c4Schristos _GL_FUNCDECL_SYS (tanf, float, (float x));
2605*fd82c4c4Schristos #  endif
2606*fd82c4c4Schristos _GL_CXXALIAS_SYS (tanf, float, (float x));
2607*fd82c4c4Schristos # endif
2608*fd82c4c4Schristos _GL_CXXALIASWARN (tanf);
2609*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2610*fd82c4c4Schristos # undef tanf
2611*fd82c4c4Schristos # if HAVE_RAW_DECL_TANF
2612*fd82c4c4Schristos _GL_WARN_ON_USE (tanf, "tanf is unportable - "
2613*fd82c4c4Schristos                  "use gnulib module tanf for portability");
2614*fd82c4c4Schristos # endif
2615*fd82c4c4Schristos #endif
2616*fd82c4c4Schristos 
2617*fd82c4c4Schristos #if 0
2618*fd82c4c4Schristos # if !1 || !1
2619*fd82c4c4Schristos #  undef tanl
2620*fd82c4c4Schristos _GL_FUNCDECL_SYS (tanl, long double, (long double x));
2621*fd82c4c4Schristos # endif
2622*fd82c4c4Schristos _GL_CXXALIAS_SYS (tanl, long double, (long double x));
2623*fd82c4c4Schristos _GL_CXXALIASWARN (tanl);
2624*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2625*fd82c4c4Schristos # undef tanl
2626*fd82c4c4Schristos # if HAVE_RAW_DECL_TANL
2627*fd82c4c4Schristos _GL_WARN_ON_USE (tanl, "tanl is unportable - "
2628*fd82c4c4Schristos                  "use gnulib module tanl for portability");
2629*fd82c4c4Schristos # endif
2630*fd82c4c4Schristos #endif
2631*fd82c4c4Schristos 
2632*fd82c4c4Schristos 
2633*fd82c4c4Schristos #if 0
2634*fd82c4c4Schristos # if 0
2635*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2636*fd82c4c4Schristos #   undef tanhf
2637*fd82c4c4Schristos #   define tanhf rpl_tanhf
2638*fd82c4c4Schristos #  endif
2639*fd82c4c4Schristos _GL_FUNCDECL_RPL (tanhf, float, (float x));
2640*fd82c4c4Schristos _GL_CXXALIAS_RPL (tanhf, float, (float x));
2641*fd82c4c4Schristos # else
2642*fd82c4c4Schristos #  if !1
2643*fd82c4c4Schristos #   undef tanhf
2644*fd82c4c4Schristos _GL_FUNCDECL_SYS (tanhf, float, (float x));
2645*fd82c4c4Schristos #  endif
2646*fd82c4c4Schristos _GL_CXXALIAS_SYS (tanhf, float, (float x));
2647*fd82c4c4Schristos # endif
2648*fd82c4c4Schristos _GL_CXXALIASWARN (tanhf);
2649*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2650*fd82c4c4Schristos # undef tanhf
2651*fd82c4c4Schristos # if HAVE_RAW_DECL_TANHF
2652*fd82c4c4Schristos _GL_WARN_ON_USE (tanhf, "tanhf is unportable - "
2653*fd82c4c4Schristos                  "use gnulib module tanhf for portability");
2654*fd82c4c4Schristos # endif
2655*fd82c4c4Schristos #endif
2656*fd82c4c4Schristos 
2657*fd82c4c4Schristos 
2658*fd82c4c4Schristos #if 0
2659*fd82c4c4Schristos # if 0
2660*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2661*fd82c4c4Schristos #   undef truncf
2662*fd82c4c4Schristos #   define truncf rpl_truncf
2663*fd82c4c4Schristos #  endif
2664*fd82c4c4Schristos _GL_FUNCDECL_RPL (truncf, float, (float x));
2665*fd82c4c4Schristos _GL_CXXALIAS_RPL (truncf, float, (float x));
2666*fd82c4c4Schristos # else
2667*fd82c4c4Schristos #  if !1
2668*fd82c4c4Schristos _GL_FUNCDECL_SYS (truncf, float, (float x));
2669*fd82c4c4Schristos #  endif
2670*fd82c4c4Schristos _GL_CXXALIAS_SYS (truncf, float, (float x));
2671*fd82c4c4Schristos # endif
2672*fd82c4c4Schristos _GL_CXXALIASWARN (truncf);
2673*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2674*fd82c4c4Schristos # undef truncf
2675*fd82c4c4Schristos # if HAVE_RAW_DECL_TRUNCF
2676*fd82c4c4Schristos _GL_WARN_ON_USE (truncf, "truncf is unportable - "
2677*fd82c4c4Schristos                  "use gnulib module truncf for portability");
2678*fd82c4c4Schristos # endif
2679*fd82c4c4Schristos #endif
2680*fd82c4c4Schristos 
2681*fd82c4c4Schristos #if 0
2682*fd82c4c4Schristos # if 0
2683*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2684*fd82c4c4Schristos #   undef trunc
2685*fd82c4c4Schristos #   define trunc rpl_trunc
2686*fd82c4c4Schristos #  endif
2687*fd82c4c4Schristos _GL_FUNCDECL_RPL (trunc, double, (double x));
2688*fd82c4c4Schristos _GL_CXXALIAS_RPL (trunc, double, (double x));
2689*fd82c4c4Schristos # else
2690*fd82c4c4Schristos #  if !1
2691*fd82c4c4Schristos _GL_FUNCDECL_SYS (trunc, double, (double x));
2692*fd82c4c4Schristos #  endif
2693*fd82c4c4Schristos _GL_CXXALIAS_SYS (trunc, double, (double x));
2694*fd82c4c4Schristos # endif
2695*fd82c4c4Schristos # if __GLIBC__ >= 2
2696*fd82c4c4Schristos _GL_CXXALIASWARN (trunc);
2697*fd82c4c4Schristos # endif
2698*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2699*fd82c4c4Schristos # undef trunc
2700*fd82c4c4Schristos # if HAVE_RAW_DECL_TRUNC
2701*fd82c4c4Schristos _GL_WARN_ON_USE (trunc, "trunc is unportable - "
2702*fd82c4c4Schristos                  "use gnulib module trunc for portability");
2703*fd82c4c4Schristos # endif
2704*fd82c4c4Schristos #endif
2705*fd82c4c4Schristos 
2706*fd82c4c4Schristos #if 0
2707*fd82c4c4Schristos # if 0
2708*fd82c4c4Schristos #  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2709*fd82c4c4Schristos #   undef truncl
2710*fd82c4c4Schristos #   define truncl rpl_truncl
2711*fd82c4c4Schristos #  endif
2712*fd82c4c4Schristos _GL_FUNCDECL_RPL (truncl, long double, (long double x));
2713*fd82c4c4Schristos _GL_CXXALIAS_RPL (truncl, long double, (long double x));
2714*fd82c4c4Schristos # else
2715*fd82c4c4Schristos #  if !1
2716*fd82c4c4Schristos _GL_FUNCDECL_SYS (truncl, long double, (long double x));
2717*fd82c4c4Schristos #  endif
2718*fd82c4c4Schristos _GL_CXXALIAS_SYS (truncl, long double, (long double x));
2719*fd82c4c4Schristos # endif
2720*fd82c4c4Schristos _GL_CXXALIASWARN (truncl);
2721*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2722*fd82c4c4Schristos # undef truncl
2723*fd82c4c4Schristos # if HAVE_RAW_DECL_TRUNCL
2724*fd82c4c4Schristos _GL_WARN_ON_USE (truncl, "truncl is unportable - "
2725*fd82c4c4Schristos                  "use gnulib module truncl for portability");
2726*fd82c4c4Schristos # endif
2727*fd82c4c4Schristos #endif
2728*fd82c4c4Schristos 
2729*fd82c4c4Schristos 
2730*fd82c4c4Schristos /* Definitions of function-like macros come here, after the function
2731*fd82c4c4Schristos    declarations.  */
2732*fd82c4c4Schristos 
2733*fd82c4c4Schristos 
2734*fd82c4c4Schristos #if 0
2735*fd82c4c4Schristos # if 0
2736*fd82c4c4Schristos _GL_EXTERN_C int gl_isfinitef (float x);
2737*fd82c4c4Schristos _GL_EXTERN_C int gl_isfinited (double x);
2738*fd82c4c4Schristos _GL_EXTERN_C int gl_isfinitel (long double x);
2739*fd82c4c4Schristos #  undef isfinite
2740*fd82c4c4Schristos #  define isfinite(x) \
2741*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? gl_isfinitel (x) : \
2742*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? gl_isfinited (x) : \
2743*fd82c4c4Schristos     gl_isfinitef (x))
2744*fd82c4c4Schristos # endif
2745*fd82c4c4Schristos # ifdef __cplusplus
2746*fd82c4c4Schristos #  if defined isfinite || defined GNULIB_NAMESPACE
2747*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isfinite)
2748*fd82c4c4Schristos #   undef isfinite
2749*fd82c4c4Schristos #   if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__ || defined _AIX))
2750*fd82c4c4Schristos   /* This platform's <cmath> possibly defines isfinite through a set of inline
2751*fd82c4c4Schristos      functions.  */
2752*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isfinite, rpl_isfinite, bool)
2753*fd82c4c4Schristos #    define isfinite rpl_isfinite
2754*fd82c4c4Schristos #   else
2755*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isfinite, isfinite, bool)
2756*fd82c4c4Schristos #   endif
2757*fd82c4c4Schristos #  endif
2758*fd82c4c4Schristos # endif
2759*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2760*fd82c4c4Schristos # if defined isfinite
2761*fd82c4c4Schristos _GL_WARN_REAL_FLOATING_DECL (isfinite);
2762*fd82c4c4Schristos #  undef isfinite
2763*fd82c4c4Schristos #  define isfinite(x) _GL_WARN_REAL_FLOATING_IMPL (isfinite, x)
2764*fd82c4c4Schristos # endif
2765*fd82c4c4Schristos #endif
2766*fd82c4c4Schristos 
2767*fd82c4c4Schristos 
2768*fd82c4c4Schristos #if 0
2769*fd82c4c4Schristos # if 0
2770*fd82c4c4Schristos _GL_EXTERN_C int gl_isinff (float x);
2771*fd82c4c4Schristos _GL_EXTERN_C int gl_isinfd (double x);
2772*fd82c4c4Schristos _GL_EXTERN_C int gl_isinfl (long double x);
2773*fd82c4c4Schristos #  undef isinf
2774*fd82c4c4Schristos #  define isinf(x) \
2775*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? gl_isinfl (x) : \
2776*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? gl_isinfd (x) : \
2777*fd82c4c4Schristos     gl_isinff (x))
2778*fd82c4c4Schristos # endif
2779*fd82c4c4Schristos # ifdef __cplusplus
2780*fd82c4c4Schristos #  if defined isinf || defined GNULIB_NAMESPACE
2781*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isinf)
2782*fd82c4c4Schristos #   undef isinf
2783*fd82c4c4Schristos #   if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__))
2784*fd82c4c4Schristos   /* This platform's <cmath> possibly defines isinf through a set of inline
2785*fd82c4c4Schristos      functions.  */
2786*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isinf, rpl_isinf, bool)
2787*fd82c4c4Schristos #    define isinf rpl_isinf
2788*fd82c4c4Schristos #   else
2789*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isinf, isinf, bool)
2790*fd82c4c4Schristos #   endif
2791*fd82c4c4Schristos #  endif
2792*fd82c4c4Schristos # endif
2793*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2794*fd82c4c4Schristos # if defined isinf
2795*fd82c4c4Schristos _GL_WARN_REAL_FLOATING_DECL (isinf);
2796*fd82c4c4Schristos #  undef isinf
2797*fd82c4c4Schristos #  define isinf(x) _GL_WARN_REAL_FLOATING_IMPL (isinf, x)
2798*fd82c4c4Schristos # endif
2799*fd82c4c4Schristos #endif
2800*fd82c4c4Schristos 
2801*fd82c4c4Schristos 
2802*fd82c4c4Schristos #if 0
2803*fd82c4c4Schristos /* Test for NaN for 'float' numbers.  */
2804*fd82c4c4Schristos # if 1
2805*fd82c4c4Schristos /* The original <math.h> included above provides a declaration of isnan macro
2806*fd82c4c4Schristos    or (older) isnanf function.  */
2807*fd82c4c4Schristos #  if __GNUC__ >= 4 && (!defined __clang__ || __has_builtin (__builtin_isnanf))
2808*fd82c4c4Schristos     /* GCC 4.0 and newer provides three built-ins for isnan.  */
2809*fd82c4c4Schristos #   undef isnanf
2810*fd82c4c4Schristos #   define isnanf(x) __builtin_isnanf ((float)(x))
2811*fd82c4c4Schristos #  elif defined isnan
2812*fd82c4c4Schristos #   undef isnanf
2813*fd82c4c4Schristos #   define isnanf(x) isnan ((float)(x))
2814*fd82c4c4Schristos #  endif
2815*fd82c4c4Schristos # else
2816*fd82c4c4Schristos /* Test whether X is a NaN.  */
2817*fd82c4c4Schristos #  undef isnanf
2818*fd82c4c4Schristos #  define isnanf rpl_isnanf
2819*fd82c4c4Schristos _GL_EXTERN_C int isnanf (float x);
2820*fd82c4c4Schristos # endif
2821*fd82c4c4Schristos #endif
2822*fd82c4c4Schristos 
2823*fd82c4c4Schristos #if 0
2824*fd82c4c4Schristos /* Test for NaN for 'double' numbers.
2825*fd82c4c4Schristos    This function is a gnulib extension, unlike isnan() which applied only
2826*fd82c4c4Schristos    to 'double' numbers earlier but now is a type-generic macro.  */
2827*fd82c4c4Schristos # if 1
2828*fd82c4c4Schristos /* The original <math.h> included above provides a declaration of isnan
2829*fd82c4c4Schristos    macro.  */
2830*fd82c4c4Schristos #  if __GNUC__ >= 4
2831*fd82c4c4Schristos     /* GCC 4.0 and newer provides three built-ins for isnan.  */
2832*fd82c4c4Schristos #   undef isnand
2833*fd82c4c4Schristos #   define isnand(x) __builtin_isnan ((double)(x))
2834*fd82c4c4Schristos #  else
2835*fd82c4c4Schristos #   undef isnand
2836*fd82c4c4Schristos #   define isnand(x) isnan ((double)(x))
2837*fd82c4c4Schristos #  endif
2838*fd82c4c4Schristos # else
2839*fd82c4c4Schristos /* Test whether X is a NaN.  */
2840*fd82c4c4Schristos #  undef isnand
2841*fd82c4c4Schristos #  define isnand rpl_isnand
2842*fd82c4c4Schristos _GL_EXTERN_C int isnand (double x);
2843*fd82c4c4Schristos # endif
2844*fd82c4c4Schristos #endif
2845*fd82c4c4Schristos 
2846*fd82c4c4Schristos #if 0
2847*fd82c4c4Schristos /* Test for NaN for 'long double' numbers.  */
2848*fd82c4c4Schristos # if 1
2849*fd82c4c4Schristos /* The original <math.h> included above provides a declaration of isnan
2850*fd82c4c4Schristos    macro or (older) isnanl function.  */
2851*fd82c4c4Schristos #  if __GNUC__ >= 4 && (!defined __clang__ || __has_builtin (__builtin_isnanl))
2852*fd82c4c4Schristos     /* GCC 4.0 and newer provides three built-ins for isnan.  */
2853*fd82c4c4Schristos #   undef isnanl
2854*fd82c4c4Schristos #   define isnanl(x) __builtin_isnanl ((long double)(x))
2855*fd82c4c4Schristos #  elif defined isnan
2856*fd82c4c4Schristos #   undef isnanl
2857*fd82c4c4Schristos #   define isnanl(x) isnan ((long double)(x))
2858*fd82c4c4Schristos #  endif
2859*fd82c4c4Schristos # else
2860*fd82c4c4Schristos /* Test whether X is a NaN.  */
2861*fd82c4c4Schristos #  undef isnanl
2862*fd82c4c4Schristos #  define isnanl rpl_isnanl
2863*fd82c4c4Schristos _GL_EXTERN_C int isnanl (long double x) _GL_ATTRIBUTE_CONST;
2864*fd82c4c4Schristos # endif
2865*fd82c4c4Schristos #endif
2866*fd82c4c4Schristos 
2867*fd82c4c4Schristos /* This must come *after* the snippets for GNULIB_ISNANF and GNULIB_ISNANL!  */
2868*fd82c4c4Schristos #if 0
2869*fd82c4c4Schristos # if 0
2870*fd82c4c4Schristos /* We can't just use the isnanf macro (e.g.) as exposed by
2871*fd82c4c4Schristos    isnanf.h (e.g.) here, because those may end up being macros
2872*fd82c4c4Schristos    that recursively expand back to isnan.  So use the gnulib
2873*fd82c4c4Schristos    replacements for them directly. */
2874*fd82c4c4Schristos #  if 1 && __GNUC__ >= 4 && (!defined __clang__ || __has_builtin (__builtin_isnanf))
2875*fd82c4c4Schristos #   define gl_isnan_f(x) __builtin_isnanf ((float)(x))
2876*fd82c4c4Schristos #  else
2877*fd82c4c4Schristos _GL_EXTERN_C int rpl_isnanf (float x);
2878*fd82c4c4Schristos #   define gl_isnan_f(x) rpl_isnanf (x)
2879*fd82c4c4Schristos #  endif
2880*fd82c4c4Schristos #  if 1 && __GNUC__ >= 4
2881*fd82c4c4Schristos #   define gl_isnan_d(x) __builtin_isnan ((double)(x))
2882*fd82c4c4Schristos #  else
2883*fd82c4c4Schristos _GL_EXTERN_C int rpl_isnand (double x);
2884*fd82c4c4Schristos #   define gl_isnan_d(x) rpl_isnand (x)
2885*fd82c4c4Schristos #  endif
2886*fd82c4c4Schristos #  if 1 && __GNUC__ >= 4 && (!defined __clang__ || __has_builtin (__builtin_isnanl))
2887*fd82c4c4Schristos #   define gl_isnan_l(x) __builtin_isnanl ((long double)(x))
2888*fd82c4c4Schristos #  else
2889*fd82c4c4Schristos _GL_EXTERN_C int rpl_isnanl (long double x) _GL_ATTRIBUTE_CONST;
2890*fd82c4c4Schristos #   define gl_isnan_l(x) rpl_isnanl (x)
2891*fd82c4c4Schristos #  endif
2892*fd82c4c4Schristos #  undef isnan
2893*fd82c4c4Schristos #  define isnan(x) \
2894*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? gl_isnan_l (x) : \
2895*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? gl_isnan_d (x) : \
2896*fd82c4c4Schristos     gl_isnan_f (x))
2897*fd82c4c4Schristos # elif __GNUC__ >= 4 && (!defined __clang__ || (__has_builtin (__builtin_isnanf) && __has_builtin (__builtin_isnanl)))
2898*fd82c4c4Schristos #  undef isnan
2899*fd82c4c4Schristos #  define isnan(x) \
2900*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? __builtin_isnanl ((long double)(x)) : \
2901*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? __builtin_isnan ((double)(x)) : \
2902*fd82c4c4Schristos     __builtin_isnanf ((float)(x)))
2903*fd82c4c4Schristos # endif
2904*fd82c4c4Schristos # ifdef __cplusplus
2905*fd82c4c4Schristos #  if defined isnan || defined GNULIB_NAMESPACE
2906*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isnan)
2907*fd82c4c4Schristos #   undef isnan
2908*fd82c4c4Schristos #   if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__))
2909*fd82c4c4Schristos   /* This platform's <cmath> possibly defines isnan through a set of inline
2910*fd82c4c4Schristos      functions.  */
2911*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isnan, rpl_isnan, bool)
2912*fd82c4c4Schristos #    define isnan rpl_isnan
2913*fd82c4c4Schristos #   else
2914*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isnan, isnan, bool)
2915*fd82c4c4Schristos #   endif
2916*fd82c4c4Schristos #  endif
2917*fd82c4c4Schristos # else
2918*fd82c4c4Schristos /* Ensure isnan is a macro.  */
2919*fd82c4c4Schristos #  ifndef isnan
2920*fd82c4c4Schristos #   define isnan isnan
2921*fd82c4c4Schristos #  endif
2922*fd82c4c4Schristos # endif
2923*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
2924*fd82c4c4Schristos # if defined isnan
2925*fd82c4c4Schristos _GL_WARN_REAL_FLOATING_DECL (isnan);
2926*fd82c4c4Schristos #  undef isnan
2927*fd82c4c4Schristos #  define isnan(x) _GL_WARN_REAL_FLOATING_IMPL (isnan, x)
2928*fd82c4c4Schristos # endif
2929*fd82c4c4Schristos #endif
2930*fd82c4c4Schristos 
2931*fd82c4c4Schristos 
2932*fd82c4c4Schristos #if 0
2933*fd82c4c4Schristos # if (0 \
2934*fd82c4c4Schristos       && (!defined __cplusplus || __cplusplus < 201103))
2935*fd82c4c4Schristos #  undef signbit
2936*fd82c4c4Schristos    /* GCC 4.0 and newer provides three built-ins for signbit.  */
2937*fd82c4c4Schristos #  define signbit(x) \
2938*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? __builtin_signbitl (x) : \
2939*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? __builtin_signbit (x) : \
2940*fd82c4c4Schristos     __builtin_signbitf (x))
2941*fd82c4c4Schristos # endif
2942*fd82c4c4Schristos # if 0 && !GNULIB_defined_signbit
2943*fd82c4c4Schristos #  undef signbit
2944*fd82c4c4Schristos _GL_EXTERN_C int gl_signbitf (float arg);
2945*fd82c4c4Schristos _GL_EXTERN_C int gl_signbitd (double arg);
2946*fd82c4c4Schristos _GL_EXTERN_C int gl_signbitl (long double arg);
2947*fd82c4c4Schristos #  if __GNUC__ >= 2 && !defined __STRICT_ANSI__
2948*fd82c4c4Schristos #   define _GL_NUM_UINT_WORDS(type) \
2949*fd82c4c4Schristos       ((sizeof (type) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
2950*fd82c4c4Schristos #   if defined FLT_SIGNBIT_WORD && defined FLT_SIGNBIT_BIT && !defined gl_signbitf
2951*fd82c4c4Schristos #    define gl_signbitf_OPTIMIZED_MACRO
2952*fd82c4c4Schristos #    define gl_signbitf(arg) \
2953*fd82c4c4Schristos        ({ union { float _value;                                         \
2954*fd82c4c4Schristos                   unsigned int _word[_GL_NUM_UINT_WORDS (float)];       \
2955*fd82c4c4Schristos                 } _m;                                                   \
2956*fd82c4c4Schristos           _m._value = (arg);                                            \
2957*fd82c4c4Schristos           (_m._word[FLT_SIGNBIT_WORD] >> FLT_SIGNBIT_BIT) & 1;          \
2958*fd82c4c4Schristos         })
2959*fd82c4c4Schristos #   endif
2960*fd82c4c4Schristos #   if defined DBL_SIGNBIT_WORD && defined DBL_SIGNBIT_BIT && !defined gl_signbitd
2961*fd82c4c4Schristos #    define gl_signbitd_OPTIMIZED_MACRO
2962*fd82c4c4Schristos #    define gl_signbitd(arg) \
2963*fd82c4c4Schristos        ({ union { double _value;                                        \
2964*fd82c4c4Schristos                   unsigned int _word[_GL_NUM_UINT_WORDS (double)];      \
2965*fd82c4c4Schristos                 } _m;                                                   \
2966*fd82c4c4Schristos           _m._value = (arg);                                            \
2967*fd82c4c4Schristos           (_m._word[DBL_SIGNBIT_WORD] >> DBL_SIGNBIT_BIT) & 1;          \
2968*fd82c4c4Schristos         })
2969*fd82c4c4Schristos #   endif
2970*fd82c4c4Schristos #   if defined LDBL_SIGNBIT_WORD && defined LDBL_SIGNBIT_BIT && !defined gl_signbitl
2971*fd82c4c4Schristos #    define gl_signbitl_OPTIMIZED_MACRO
2972*fd82c4c4Schristos #    define gl_signbitl(arg) \
2973*fd82c4c4Schristos        ({ union { long double _value;                                   \
2974*fd82c4c4Schristos                   unsigned int _word[_GL_NUM_UINT_WORDS (long double)]; \
2975*fd82c4c4Schristos                 } _m;                                                   \
2976*fd82c4c4Schristos           _m._value = (arg);                                            \
2977*fd82c4c4Schristos           (_m._word[LDBL_SIGNBIT_WORD] >> LDBL_SIGNBIT_BIT) & 1;        \
2978*fd82c4c4Schristos         })
2979*fd82c4c4Schristos #   endif
2980*fd82c4c4Schristos #  endif
2981*fd82c4c4Schristos #  define signbit(x) \
2982*fd82c4c4Schristos    (sizeof (x) == sizeof (long double) ? gl_signbitl (x) : \
2983*fd82c4c4Schristos     sizeof (x) == sizeof (double) ? gl_signbitd (x) : \
2984*fd82c4c4Schristos     gl_signbitf (x))
2985*fd82c4c4Schristos #  define GNULIB_defined_signbit 1
2986*fd82c4c4Schristos # endif
2987*fd82c4c4Schristos # ifdef __cplusplus
2988*fd82c4c4Schristos #  if defined signbit || defined GNULIB_NAMESPACE
2989*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_1 (signbit)
2990*fd82c4c4Schristos #   undef signbit
2991*fd82c4c4Schristos #   if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__ || defined _AIX))
2992*fd82c4c4Schristos   /* This platform's <cmath> possibly defines signbit through a set of inline
2993*fd82c4c4Schristos      functions.  */
2994*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (signbit, rpl_signbit, bool)
2995*fd82c4c4Schristos #    define signbit rpl_signbit
2996*fd82c4c4Schristos #   else
2997*fd82c4c4Schristos _GL_MATH_CXX_REAL_FLOATING_DECL_2 (signbit, signbit, bool)
2998*fd82c4c4Schristos #   endif
2999*fd82c4c4Schristos #  endif
3000*fd82c4c4Schristos # endif
3001*fd82c4c4Schristos #elif defined GNULIB_POSIXCHECK
3002*fd82c4c4Schristos # if defined signbit
3003*fd82c4c4Schristos _GL_WARN_REAL_FLOATING_DECL (signbit);
3004*fd82c4c4Schristos #  undef signbit
3005*fd82c4c4Schristos #  define signbit(x) _GL_WARN_REAL_FLOATING_IMPL (signbit, x)
3006*fd82c4c4Schristos # endif
3007*fd82c4c4Schristos #endif
3008*fd82c4c4Schristos 
3009*fd82c4c4Schristos _GL_INLINE_HEADER_END
3010*fd82c4c4Schristos 
3011*fd82c4c4Schristos #endif /* _GL_MATH_H */
3012*fd82c4c4Schristos #endif /* _GL_MATH_H */
3013