Merge branch 'master' of github.com:monitoring-plugins/monitoring-plugins
[monitoring-plugins.git] / gl / math.in.h
blobf3d58afc0de2321c82c1a502c1a68337913cfeff
1 /* A GNU-like <math.h>.
3 Copyright (C) 2002-2003, 2007-2023 Free Software Foundation, Inc.
5 This file is free software: you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as
7 published by the Free Software Foundation; either version 2.1 of the
8 License, or (at your option) any later version.
10 This file is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public License
16 along with this program. If not, see <https://www.gnu.org/licenses/>. */
18 #ifndef _@GUARD_PREFIX@_MATH_H
20 #if __GNUC__ >= 3
21 @PRAGMA_SYSTEM_HEADER@
22 #endif
23 @PRAGMA_COLUMNS@
25 #if defined _GL_INCLUDING_MATH_H
26 /* Special invocation convention:
27 - On FreeBSD 12.2 we have a sequence of nested includes
28 <math.h> -> <stdlib.h> -> <sys/wait.h> -> <sys/types.h> -> <sys/select.h>
29 -> <signal.h> -> <pthread.h> -> <stdlib.h> -> <math.h>
30 In this situation, the functions are not yet declared, therefore we cannot
31 provide the C++ aliases. */
33 #@INCLUDE_NEXT_AS_FIRST_DIRECTIVE@ @NEXT_AS_FIRST_DIRECTIVE_MATH_H@
35 #else
36 /* Normal invocation convention. */
38 /* The include_next requires a split double-inclusion guard. */
39 #define _GL_INCLUDING_MATH_H
40 #@INCLUDE_NEXT_AS_FIRST_DIRECTIVE@ @NEXT_AS_FIRST_DIRECTIVE_MATH_H@
41 #undef _GL_INCLUDING_MATH_H
43 #ifndef _@GUARD_PREFIX@_MATH_H
44 #define _@GUARD_PREFIX@_MATH_H
46 /* On OpenVMS, NAN, INFINITY, and HUGEVAL macros are defined in <fp.h>. */
47 #if defined __VMS && ! defined NAN
48 # include <fp.h>
49 #endif
51 #ifndef _GL_INLINE_HEADER_BEGIN
52 #error "Please include config.h first."
53 #endif
54 _GL_INLINE_HEADER_BEGIN
55 #ifndef _GL_MATH_INLINE
56 # define _GL_MATH_INLINE _GL_INLINE
57 #endif
59 /* The __attribute__ feature is available in gcc versions 2.5 and later.
60 The attribute __const__ was added in gcc 2.95. */
61 #ifndef _GL_ATTRIBUTE_CONST
62 # if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) || defined __clang__
63 # define _GL_ATTRIBUTE_CONST __attribute__ ((__const__))
64 # else
65 # define _GL_ATTRIBUTE_CONST /* empty */
66 # endif
67 #endif
69 /* The definitions of _GL_FUNCDECL_RPL etc. are copied here. */
71 /* The definition of _GL_ARG_NONNULL is copied here. */
73 /* The definition of _GL_WARN_ON_USE is copied here. */
75 #ifdef __cplusplus
76 /* Helper macros to define type-generic function FUNC as overloaded functions,
77 rather than as macros like in C. POSIX declares these with an argument of
78 real-floating (that is, one of float, double, or long double). */
79 # define _GL_MATH_CXX_REAL_FLOATING_DECL_1(func) \
80 static inline int \
81 _gl_cxx_ ## func ## f (float f) \
82 { \
83 return func (f); \
84 } \
85 static inline int \
86 _gl_cxx_ ## func ## d (double d) \
87 { \
88 return func (d); \
89 } \
90 static inline int \
91 _gl_cxx_ ## func ## l (long double l) \
92 { \
93 return func (l); \
95 # define _GL_MATH_CXX_REAL_FLOATING_DECL_2(func,rpl_func,rettype) \
96 _GL_BEGIN_NAMESPACE \
97 inline rettype \
98 rpl_func (float f) \
99 { \
100 return _gl_cxx_ ## func ## f (f); \
102 inline rettype \
103 rpl_func (double d) \
105 return _gl_cxx_ ## func ## d (d); \
107 inline rettype \
108 rpl_func (long double l) \
110 return _gl_cxx_ ## func ## l (l); \
112 _GL_END_NAMESPACE
113 #endif
115 /* Helper macros to define a portability warning for the
116 classification macro FUNC called with VALUE. POSIX declares the
117 classification macros with an argument of real-floating (that is,
118 one of float, double, or long double). */
119 #define _GL_WARN_REAL_FLOATING_DECL(func) \
120 _GL_MATH_INLINE int \
121 _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - " \
122 "use gnulib module " #func " for portability") \
123 rpl_ ## func ## f (float f) \
125 return func (f); \
127 _GL_MATH_INLINE int \
128 _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - " \
129 "use gnulib module " #func " for portability") \
130 rpl_ ## func ## d (double d) \
132 return func (d); \
134 _GL_MATH_INLINE int \
135 _GL_WARN_ON_USE_ATTRIBUTE (#func " is unportable - " \
136 "use gnulib module " #func " for portability") \
137 rpl_ ## func ## l (long double l) \
139 return func (l); \
141 #define _GL_WARN_REAL_FLOATING_IMPL(func, value) \
142 (sizeof (value) == sizeof (float) ? rpl_ ## func ## f (value) \
143 : sizeof (value) == sizeof (double) ? rpl_ ## func ## d (value) \
144 : rpl_ ## func ## l (value))
147 #if @REPLACE_ITOLD@
148 /* Pull in a function that fixes the 'int' to 'long double' conversion
149 of glibc 2.7. */
150 _GL_EXTERN_C void _Qp_itoq (long double *, int);
151 static void (*_gl_math_fix_itold) (long double *, int) = _Qp_itoq;
152 #endif
155 /* POSIX allows platforms that don't support NAN. But all major
156 machines in the past 15 years have supported something close to
157 IEEE NaN, so we define this unconditionally. We also must define
158 it on platforms like Solaris 10, where NAN is present but defined
159 as a function pointer rather than a floating point constant. */
160 #if !defined NAN || @REPLACE_NAN@
161 # if !GNULIB_defined_NAN
162 # undef NAN
163 /* The Compaq (ex-DEC) C 6.4 compiler and the Microsoft MSVC 9 compiler
164 choke on the expression 0.0 / 0.0. */
165 # if defined __DECC || defined _MSC_VER
166 _GL_MATH_INLINE float
167 _NaN ()
169 static float zero = 0.0f;
170 return zero / zero;
172 # define NAN (_NaN())
173 # else
174 # define NAN (0.0f / 0.0f)
175 # endif
176 # define GNULIB_defined_NAN 1
177 # endif
178 #endif
180 /* Solaris 10 defines HUGE_VAL, but as a function pointer rather
181 than a floating point constant. */
182 #if @REPLACE_HUGE_VAL@
183 # undef HUGE_VALF
184 # define HUGE_VALF (1.0f / 0.0f)
185 # undef HUGE_VAL
186 # define HUGE_VAL (1.0 / 0.0)
187 # undef HUGE_VALL
188 # define HUGE_VALL (1.0L / 0.0L)
189 #endif
191 /* HUGE_VALF is a 'float' Infinity. */
192 #ifndef HUGE_VALF
193 # if defined _MSC_VER
194 /* The Microsoft MSVC 9 compiler chokes on the expression 1.0f / 0.0f. */
195 # define HUGE_VALF (1e25f * 1e25f)
196 # else
197 # define HUGE_VALF (1.0f / 0.0f)
198 # endif
199 #endif
201 /* HUGE_VAL is a 'double' Infinity. */
202 #ifndef HUGE_VAL
203 # if defined _MSC_VER
204 /* The Microsoft MSVC 9 compiler chokes on the expression 1.0 / 0.0. */
205 # define HUGE_VAL (1e250 * 1e250)
206 # else
207 # define HUGE_VAL (1.0 / 0.0)
208 # endif
209 #endif
211 /* HUGE_VALL is a 'long double' Infinity. */
212 #ifndef HUGE_VALL
213 # if defined _MSC_VER
214 /* The Microsoft MSVC 9 compiler chokes on the expression 1.0L / 0.0L. */
215 # define HUGE_VALL (1e250L * 1e250L)
216 # else
217 # define HUGE_VALL (1.0L / 0.0L)
218 # endif
219 #endif
222 #if defined FP_ILOGB0 && defined FP_ILOGBNAN
223 /* Ensure FP_ILOGB0 and FP_ILOGBNAN are correct. */
224 # if defined __HAIKU__
225 /* Haiku: match what ilogb() does */
226 # undef FP_ILOGB0
227 # undef FP_ILOGBNAN
228 # define FP_ILOGB0 (- 2147483647 - 1) /* INT_MIN */
229 # define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
230 # endif
231 #else
232 /* Ensure FP_ILOGB0 and FP_ILOGBNAN are defined. */
233 # if defined __NetBSD__ || defined __sgi
234 /* NetBSD, IRIX 6.5: match what ilogb() does */
235 # define FP_ILOGB0 (- 2147483647 - 1) /* INT_MIN */
236 # define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
237 # elif defined _AIX
238 /* AIX 5.1: match what ilogb() does in AIX >= 5.2 */
239 # define FP_ILOGB0 (- 2147483647 - 1) /* INT_MIN */
240 # define FP_ILOGBNAN 2147483647 /* INT_MAX */
241 # elif defined __sun
242 /* Solaris 9: match what ilogb() does */
243 # define FP_ILOGB0 (- 2147483647) /* - INT_MAX */
244 # define FP_ILOGBNAN 2147483647 /* INT_MAX */
245 # else
246 /* Gnulib defined values. */
247 # define FP_ILOGB0 (- 2147483647) /* - INT_MAX */
248 # define FP_ILOGBNAN (- 2147483647 - 1) /* INT_MIN */
249 # endif
250 #endif
253 #if @GNULIB_ACOSF@
254 # if @REPLACE_ACOSF@
255 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
256 # undef acosf
257 # define acosf rpl_acosf
258 # endif
259 _GL_FUNCDECL_RPL (acosf, float, (float x));
260 _GL_CXXALIAS_RPL (acosf, float, (float x));
261 # else
262 # if !@HAVE_ACOSF@
263 # undef acosf
264 _GL_FUNCDECL_SYS (acosf, float, (float x));
265 # endif
266 _GL_CXXALIAS_SYS (acosf, float, (float x));
267 # endif
268 _GL_CXXALIASWARN (acosf);
269 #elif defined GNULIB_POSIXCHECK
270 # undef acosf
271 # if HAVE_RAW_DECL_ACOSF
272 _GL_WARN_ON_USE (acosf, "acosf is unportable - "
273 "use gnulib module acosf for portability");
274 # endif
275 #endif
277 #if @GNULIB_ACOSL@
278 # if !@HAVE_ACOSL@ || !@HAVE_DECL_ACOSL@
279 # undef acosl
280 _GL_FUNCDECL_SYS (acosl, long double, (long double x));
281 # endif
282 _GL_CXXALIAS_SYS (acosl, long double, (long double x));
283 # if __GLIBC__ >= 2
284 _GL_CXXALIASWARN (acosl);
285 # endif
286 #elif defined GNULIB_POSIXCHECK
287 # undef acosl
288 # if HAVE_RAW_DECL_ACOSL
289 _GL_WARN_ON_USE (acosl, "acosl is unportable - "
290 "use gnulib module acosl for portability");
291 # endif
292 #endif
295 #if @GNULIB_ASINF@
296 # if @REPLACE_ASINF@
297 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
298 # undef asinf
299 # define asinf rpl_asinf
300 # endif
301 _GL_FUNCDECL_RPL (asinf, float, (float x));
302 _GL_CXXALIAS_RPL (asinf, float, (float x));
303 # else
304 # if !@HAVE_ASINF@
305 # undef asinf
306 _GL_FUNCDECL_SYS (asinf, float, (float x));
307 # endif
308 _GL_CXXALIAS_SYS (asinf, float, (float x));
309 # endif
310 _GL_CXXALIASWARN (asinf);
311 #elif defined GNULIB_POSIXCHECK
312 # undef asinf
313 # if HAVE_RAW_DECL_ASINF
314 _GL_WARN_ON_USE (asinf, "asinf is unportable - "
315 "use gnulib module asinf for portability");
316 # endif
317 #endif
319 #if @GNULIB_ASINL@
320 # if !@HAVE_ASINL@ || !@HAVE_DECL_ASINL@
321 # undef asinl
322 _GL_FUNCDECL_SYS (asinl, long double, (long double x));
323 # endif
324 _GL_CXXALIAS_SYS (asinl, long double, (long double x));
325 # if __GLIBC__ >= 2
326 _GL_CXXALIASWARN (asinl);
327 # endif
328 #elif defined GNULIB_POSIXCHECK
329 # undef asinl
330 # if HAVE_RAW_DECL_ASINL
331 _GL_WARN_ON_USE (asinl, "asinl is unportable - "
332 "use gnulib module asinl for portability");
333 # endif
334 #endif
337 #if @GNULIB_ATANF@
338 # if @REPLACE_ATANF@
339 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
340 # undef atanf
341 # define atanf rpl_atanf
342 # endif
343 _GL_FUNCDECL_RPL (atanf, float, (float x));
344 _GL_CXXALIAS_RPL (atanf, float, (float x));
345 # else
346 # if !@HAVE_ATANF@
347 # undef atanf
348 _GL_FUNCDECL_SYS (atanf, float, (float x));
349 # endif
350 _GL_CXXALIAS_SYS (atanf, float, (float x));
351 # endif
352 _GL_CXXALIASWARN (atanf);
353 #elif defined GNULIB_POSIXCHECK
354 # undef atanf
355 # if HAVE_RAW_DECL_ATANF
356 _GL_WARN_ON_USE (atanf, "atanf is unportable - "
357 "use gnulib module atanf for portability");
358 # endif
359 #endif
361 #if @GNULIB_ATANL@
362 # if !@HAVE_ATANL@ || !@HAVE_DECL_ATANL@
363 # undef atanl
364 _GL_FUNCDECL_SYS (atanl, long double, (long double x));
365 # endif
366 _GL_CXXALIAS_SYS (atanl, long double, (long double x));
367 # if __GLIBC__ >= 2
368 _GL_CXXALIASWARN (atanl);
369 # endif
370 #elif defined GNULIB_POSIXCHECK
371 # undef atanl
372 # if HAVE_RAW_DECL_ATANL
373 _GL_WARN_ON_USE (atanl, "atanl is unportable - "
374 "use gnulib module atanl for portability");
375 # endif
376 #endif
379 #if @GNULIB_ATAN2F@
380 # if @REPLACE_ATAN2F@
381 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
382 # undef atan2f
383 # define atan2f rpl_atan2f
384 # endif
385 _GL_FUNCDECL_RPL (atan2f, float, (float y, float x));
386 _GL_CXXALIAS_RPL (atan2f, float, (float y, float x));
387 # else
388 # if !@HAVE_ATAN2F@
389 # undef atan2f
390 _GL_FUNCDECL_SYS (atan2f, float, (float y, float x));
391 # endif
392 _GL_CXXALIAS_SYS (atan2f, float, (float y, float x));
393 # endif
394 _GL_CXXALIASWARN (atan2f);
395 #elif defined GNULIB_POSIXCHECK
396 # undef atan2f
397 # if HAVE_RAW_DECL_ATAN2F
398 _GL_WARN_ON_USE (atan2f, "atan2f is unportable - "
399 "use gnulib module atan2f for portability");
400 # endif
401 #endif
404 #if @GNULIB_CBRTF@
405 # if @REPLACE_CBRTF@
406 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
407 # undef cbrtf
408 # define cbrtf rpl_cbrtf
409 # endif
410 _GL_FUNCDECL_RPL (cbrtf, float, (float x));
411 _GL_CXXALIAS_RPL (cbrtf, float, (float x));
412 # else
413 # if !@HAVE_DECL_CBRTF@
414 _GL_FUNCDECL_SYS (cbrtf, float, (float x));
415 # endif
416 _GL_CXXALIAS_SYS (cbrtf, float, (float x));
417 # endif
418 _GL_CXXALIASWARN (cbrtf);
419 #elif defined GNULIB_POSIXCHECK
420 # undef cbrtf
421 # if HAVE_RAW_DECL_CBRTF
422 _GL_WARN_ON_USE (cbrtf, "cbrtf is unportable - "
423 "use gnulib module cbrtf for portability");
424 # endif
425 #endif
427 #if @GNULIB_CBRT@
428 # if !@HAVE_CBRT@
429 _GL_FUNCDECL_SYS (cbrt, double, (double x));
430 # endif
431 _GL_CXXALIAS_SYS (cbrt, double, (double x));
432 # if __GLIBC__ >= 2
433 _GL_CXXALIASWARN1 (cbrt, double, (double x));
434 # endif
435 #elif defined GNULIB_POSIXCHECK
436 # undef cbrt
437 # if HAVE_RAW_DECL_CBRT
438 _GL_WARN_ON_USE (cbrt, "cbrt is unportable - "
439 "use gnulib module cbrt for portability");
440 # endif
441 #endif
443 #if @GNULIB_CBRTL@
444 # if @REPLACE_CBRTL@
445 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
446 # undef cbrtl
447 # define cbrtl rpl_cbrtl
448 # endif
449 _GL_FUNCDECL_RPL (cbrtl, long double, (long double x));
450 _GL_CXXALIAS_RPL (cbrtl, long double, (long double x));
451 # else
452 # if !@HAVE_DECL_CBRTL@
453 _GL_FUNCDECL_SYS (cbrtl, long double, (long double x));
454 # endif
455 _GL_CXXALIAS_SYS (cbrtl, long double, (long double x));
456 # endif
457 # if __GLIBC__ >= 2
458 _GL_CXXALIASWARN (cbrtl);
459 # endif
460 #elif defined GNULIB_POSIXCHECK
461 # undef cbrtl
462 # if HAVE_RAW_DECL_CBRTL
463 _GL_WARN_ON_USE (cbrtl, "cbrtl is unportable - "
464 "use gnulib module cbrtl for portability");
465 # endif
466 #endif
469 #if @GNULIB_CEILF@
470 # if @REPLACE_CEILF@
471 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
472 # undef ceilf
473 # define ceilf rpl_ceilf
474 # endif
475 _GL_FUNCDECL_RPL (ceilf, float, (float x));
476 _GL_CXXALIAS_RPL (ceilf, float, (float x));
477 # else
478 # if !@HAVE_DECL_CEILF@
479 # undef ceilf
480 _GL_FUNCDECL_SYS (ceilf, float, (float x));
481 # endif
482 _GL_CXXALIAS_SYS (ceilf, float, (float x));
483 # endif
484 _GL_CXXALIASWARN (ceilf);
485 #elif defined GNULIB_POSIXCHECK
486 # undef ceilf
487 # if HAVE_RAW_DECL_CEILF
488 _GL_WARN_ON_USE (ceilf, "ceilf is unportable - "
489 "use gnulib module ceilf for portability");
490 # endif
491 #endif
493 #if @GNULIB_CEIL@
494 # if @REPLACE_CEIL@
495 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
496 # undef ceil
497 # define ceil rpl_ceil
498 # endif
499 _GL_FUNCDECL_RPL (ceil, double, (double x));
500 _GL_CXXALIAS_RPL (ceil, double, (double x));
501 # else
502 _GL_CXXALIAS_SYS (ceil, double, (double x));
503 # endif
504 # if __GLIBC__ >= 2
505 _GL_CXXALIASWARN1 (ceil, double, (double x));
506 # endif
507 #endif
509 #if @GNULIB_CEILL@
510 # if @REPLACE_CEILL@
511 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
512 # undef ceill
513 # define ceill rpl_ceill
514 # endif
515 _GL_FUNCDECL_RPL (ceill, long double, (long double x));
516 _GL_CXXALIAS_RPL (ceill, long double, (long double x));
517 # else
518 # if !@HAVE_DECL_CEILL@
519 # undef ceill
520 _GL_FUNCDECL_SYS (ceill, long double, (long double x));
521 # endif
522 _GL_CXXALIAS_SYS (ceill, long double, (long double x));
523 # endif
524 # if __GLIBC__ >= 2
525 _GL_CXXALIASWARN (ceill);
526 # endif
527 #elif defined GNULIB_POSIXCHECK
528 # undef ceill
529 # if HAVE_RAW_DECL_CEILL
530 _GL_WARN_ON_USE (ceill, "ceill is unportable - "
531 "use gnulib module ceill for portability");
532 # endif
533 #endif
536 #if @GNULIB_COPYSIGNF@
537 # if !@HAVE_DECL_COPYSIGNF@
538 # undef copysignf
539 _GL_FUNCDECL_SYS (copysignf, float, (float x, float y));
540 # endif
541 _GL_CXXALIAS_SYS (copysignf, float, (float x, float y));
542 _GL_CXXALIASWARN (copysignf);
543 #elif defined GNULIB_POSIXCHECK
544 # undef copysignf
545 # if HAVE_RAW_DECL_COPYSIGNF
546 _GL_WARN_ON_USE (copysignf, "copysignf is unportable - "
547 "use gnulib module copysignf for portability");
548 # endif
549 #endif
551 #if @GNULIB_COPYSIGN@
552 # if !@HAVE_COPYSIGN@
553 _GL_FUNCDECL_SYS (copysign, double, (double x, double y));
554 # endif
555 _GL_CXXALIAS_SYS (copysign, double, (double x, double y));
556 # if __GLIBC__ >= 2
557 _GL_CXXALIASWARN1 (copysign, double, (double x, double y));
558 # endif
559 #elif defined GNULIB_POSIXCHECK
560 # undef copysign
561 # if HAVE_RAW_DECL_COPYSIGN
562 _GL_WARN_ON_USE (copysign, "copysign is unportable - "
563 "use gnulib module copysign for portability");
564 # endif
565 #endif
567 #if @GNULIB_COPYSIGNL@
568 # if !@HAVE_COPYSIGNL@
569 _GL_FUNCDECL_SYS (copysignl, long double, (long double x, long double y));
570 # endif
571 _GL_CXXALIAS_SYS (copysignl, long double, (long double x, long double y));
572 # if __GLIBC__ >= 2
573 _GL_CXXALIASWARN (copysignl);
574 # endif
575 #elif defined GNULIB_POSIXCHECK
576 # undef copysignl
577 # if HAVE_RAW_DECL_COPYSIGNL
578 _GL_WARN_ON_USE (copysign, "copysignl is unportable - "
579 "use gnulib module copysignl for portability");
580 # endif
581 #endif
584 #if @GNULIB_COSF@
585 # if @REPLACE_COSF@
586 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
587 # undef cosf
588 # define cosf rpl_cosf
589 # endif
590 _GL_FUNCDECL_RPL (cosf, float, (float x));
591 _GL_CXXALIAS_RPL (cosf, float, (float x));
592 # else
593 # if !@HAVE_COSF@
594 # undef cosf
595 _GL_FUNCDECL_SYS (cosf, float, (float x));
596 # endif
597 _GL_CXXALIAS_SYS (cosf, float, (float x));
598 # endif
599 _GL_CXXALIASWARN (cosf);
600 #elif defined GNULIB_POSIXCHECK
601 # undef cosf
602 # if HAVE_RAW_DECL_COSF
603 _GL_WARN_ON_USE (cosf, "cosf is unportable - "
604 "use gnulib module cosf for portability");
605 # endif
606 #endif
608 #if @GNULIB_COSL@
609 # if !@HAVE_COSL@ || !@HAVE_DECL_COSL@
610 # undef cosl
611 _GL_FUNCDECL_SYS (cosl, long double, (long double x));
612 # endif
613 _GL_CXXALIAS_SYS (cosl, long double, (long double x));
614 # if __GLIBC__ >= 2
615 _GL_CXXALIASWARN (cosl);
616 # endif
617 #elif defined GNULIB_POSIXCHECK
618 # undef cosl
619 # if HAVE_RAW_DECL_COSL
620 _GL_WARN_ON_USE (cosl, "cosl is unportable - "
621 "use gnulib module cosl for portability");
622 # endif
623 #endif
626 #if @GNULIB_COSHF@
627 # if @REPLACE_COSHF@
628 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
629 # undef coshf
630 # define coshf rpl_coshf
631 # endif
632 _GL_FUNCDECL_RPL (coshf, float, (float x));
633 _GL_CXXALIAS_RPL (coshf, float, (float x));
634 # else
635 # if !@HAVE_COSHF@
636 # undef coshf
637 _GL_FUNCDECL_SYS (coshf, float, (float x));
638 # endif
639 _GL_CXXALIAS_SYS (coshf, float, (float x));
640 # endif
641 _GL_CXXALIASWARN (coshf);
642 #elif defined GNULIB_POSIXCHECK
643 # undef coshf
644 # if HAVE_RAW_DECL_COSHF
645 _GL_WARN_ON_USE (coshf, "coshf is unportable - "
646 "use gnulib module coshf for portability");
647 # endif
648 #endif
651 #if @GNULIB_EXPF@
652 # if @REPLACE_EXPF@
653 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
654 # undef expf
655 # define expf rpl_expf
656 # endif
657 _GL_FUNCDECL_RPL (expf, float, (float x));
658 _GL_CXXALIAS_RPL (expf, float, (float x));
659 # else
660 # if !@HAVE_EXPF@
661 # undef expf
662 _GL_FUNCDECL_SYS (expf, float, (float x));
663 # endif
664 _GL_CXXALIAS_SYS (expf, float, (float x));
665 # endif
666 _GL_CXXALIASWARN (expf);
667 #elif defined GNULIB_POSIXCHECK
668 # undef expf
669 # if HAVE_RAW_DECL_EXPF
670 _GL_WARN_ON_USE (expf, "expf is unportable - "
671 "use gnulib module expf for portability");
672 # endif
673 #endif
675 #if @GNULIB_EXPL@
676 # if @REPLACE_EXPL@
677 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
678 # undef expl
679 # define expl rpl_expl
680 # endif
681 _GL_FUNCDECL_RPL (expl, long double, (long double x));
682 _GL_CXXALIAS_RPL (expl, long double, (long double x));
683 # else
684 # if !@HAVE_EXPL@ || !@HAVE_DECL_EXPL@
685 # undef expl
686 _GL_FUNCDECL_SYS (expl, long double, (long double x));
687 # endif
688 _GL_CXXALIAS_SYS (expl, long double, (long double x));
689 # endif
690 # if __GLIBC__ >= 2
691 _GL_CXXALIASWARN (expl);
692 # endif
693 #elif defined GNULIB_POSIXCHECK
694 # undef expl
695 # if HAVE_RAW_DECL_EXPL
696 _GL_WARN_ON_USE (expl, "expl is unportable - "
697 "use gnulib module expl for portability");
698 # endif
699 #endif
702 #if @GNULIB_EXP2F@
703 # if !@HAVE_DECL_EXP2F@
704 _GL_FUNCDECL_SYS (exp2f, float, (float x));
705 # endif
706 _GL_CXXALIAS_SYS (exp2f, float, (float x));
707 _GL_CXXALIASWARN (exp2f);
708 #elif defined GNULIB_POSIXCHECK
709 # undef exp2f
710 # if HAVE_RAW_DECL_EXP2F
711 _GL_WARN_ON_USE (exp2f, "exp2f is unportable - "
712 "use gnulib module exp2f for portability");
713 # endif
714 #endif
716 #if @GNULIB_EXP2@
717 # if @REPLACE_EXP2@
718 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
719 # undef exp2
720 # define exp2 rpl_exp2
721 # endif
722 _GL_FUNCDECL_RPL (exp2, double, (double x));
723 _GL_CXXALIAS_RPL (exp2, double, (double x));
724 # else
725 # if !@HAVE_DECL_EXP2@
726 _GL_FUNCDECL_SYS (exp2, double, (double x));
727 # endif
728 _GL_CXXALIAS_SYS (exp2, double, (double x));
729 # endif
730 # if __GLIBC__ >= 2
731 _GL_CXXALIASWARN1 (exp2, double, (double x));
732 # endif
733 #elif defined GNULIB_POSIXCHECK
734 # undef exp2
735 # if HAVE_RAW_DECL_EXP2
736 _GL_WARN_ON_USE (exp2, "exp2 is unportable - "
737 "use gnulib module exp2 for portability");
738 # endif
739 #endif
741 #if @GNULIB_EXP2L@
742 # if @REPLACE_EXP2L@
743 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
744 # undef exp2l
745 # define exp2l rpl_exp2l
746 # endif
747 _GL_FUNCDECL_RPL (exp2l, long double, (long double x));
748 _GL_CXXALIAS_RPL (exp2l, long double, (long double x));
749 # else
750 # if !@HAVE_DECL_EXP2L@
751 # undef exp2l
752 _GL_FUNCDECL_SYS (exp2l, long double, (long double x));
753 # endif
754 _GL_CXXALIAS_SYS (exp2l, long double, (long double x));
755 # endif
756 # if __GLIBC__ >= 2
757 _GL_CXXALIASWARN (exp2l);
758 # endif
759 #elif defined GNULIB_POSIXCHECK
760 # undef exp2l
761 # if HAVE_RAW_DECL_EXP2L
762 _GL_WARN_ON_USE (exp2l, "exp2l is unportable - "
763 "use gnulib module exp2l for portability");
764 # endif
765 #endif
768 #if @GNULIB_EXPM1F@
769 # if @REPLACE_EXPM1F@
770 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
771 # undef expm1f
772 # define expm1f rpl_expm1f
773 # endif
774 _GL_FUNCDECL_RPL (expm1f, float, (float x));
775 _GL_CXXALIAS_RPL (expm1f, float, (float x));
776 # else
777 # if !@HAVE_EXPM1F@
778 _GL_FUNCDECL_SYS (expm1f, float, (float x));
779 # endif
780 _GL_CXXALIAS_SYS (expm1f, float, (float x));
781 # endif
782 _GL_CXXALIASWARN (expm1f);
783 #elif defined GNULIB_POSIXCHECK
784 # undef expm1f
785 # if HAVE_RAW_DECL_EXPM1F
786 _GL_WARN_ON_USE (expm1f, "expm1f is unportable - "
787 "use gnulib module expm1f for portability");
788 # endif
789 #endif
791 #if @GNULIB_EXPM1@
792 # if @REPLACE_EXPM1@
793 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
794 # undef expm1
795 # define expm1 rpl_expm1
796 # endif
797 _GL_FUNCDECL_RPL (expm1, double, (double x));
798 _GL_CXXALIAS_RPL (expm1, double, (double x));
799 # else
800 # if !@HAVE_EXPM1@
801 _GL_FUNCDECL_SYS (expm1, double, (double x));
802 # endif
803 _GL_CXXALIAS_SYS (expm1, double, (double x));
804 # endif
805 # if __GLIBC__ >= 2
806 _GL_CXXALIASWARN1 (expm1, double, (double x));
807 # endif
808 #elif defined GNULIB_POSIXCHECK
809 # undef expm1
810 # if HAVE_RAW_DECL_EXPM1
811 _GL_WARN_ON_USE (expm1, "expm1 is unportable - "
812 "use gnulib module expm1 for portability");
813 # endif
814 #endif
816 #if @GNULIB_EXPM1L@
817 # if @REPLACE_EXPM1L@
818 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
819 # undef expm1l
820 # define expm1l rpl_expm1l
821 # endif
822 _GL_FUNCDECL_RPL (expm1l, long double, (long double x));
823 _GL_CXXALIAS_RPL (expm1l, long double, (long double x));
824 # else
825 # if !@HAVE_DECL_EXPM1L@
826 # undef expm1l
827 # if !(defined __cplusplus && defined _AIX)
828 _GL_FUNCDECL_SYS (expm1l, long double, (long double x));
829 # endif
830 # endif
831 _GL_CXXALIAS_SYS (expm1l, long double, (long double x));
832 # endif
833 # if __GLIBC__ >= 2
834 _GL_CXXALIASWARN (expm1l);
835 # endif
836 #elif defined GNULIB_POSIXCHECK
837 # undef expm1l
838 # if HAVE_RAW_DECL_EXPM1L
839 _GL_WARN_ON_USE (expm1l, "expm1l is unportable - "
840 "use gnulib module expm1l for portability");
841 # endif
842 #endif
845 #if @GNULIB_FABSF@
846 # if !@HAVE_FABSF@
847 # undef fabsf
848 _GL_FUNCDECL_SYS (fabsf, float, (float x));
849 # endif
850 _GL_CXXALIAS_SYS (fabsf, float, (float x));
851 # if __GLIBC__ >= 2
852 _GL_CXXALIASWARN (fabsf);
853 # endif
854 #elif defined GNULIB_POSIXCHECK
855 # undef fabsf
856 # if HAVE_RAW_DECL_FABSF
857 _GL_WARN_ON_USE (fabsf, "fabsf is unportable - "
858 "use gnulib module fabsf for portability");
859 # endif
860 #endif
862 #if @GNULIB_FABSL@
863 # if @REPLACE_FABSL@
864 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
865 # undef fabsl
866 # define fabsl rpl_fabsl
867 # endif
868 _GL_FUNCDECL_RPL (fabsl, long double, (long double x));
869 _GL_CXXALIAS_RPL (fabsl, long double, (long double x));
870 # else
871 # if !@HAVE_FABSL@
872 # undef fabsl
873 _GL_FUNCDECL_SYS (fabsl, long double, (long double x));
874 # endif
875 _GL_CXXALIAS_SYS (fabsl, long double, (long double x));
876 # endif
877 # if __GLIBC__ >= 2
878 _GL_CXXALIASWARN (fabsl);
879 # endif
880 #elif defined GNULIB_POSIXCHECK
881 # undef fabsl
882 # if HAVE_RAW_DECL_FABSL
883 _GL_WARN_ON_USE (fabsl, "fabsl is unportable - "
884 "use gnulib module fabsl for portability");
885 # endif
886 #endif
889 #if @GNULIB_FLOORF@
890 # if @REPLACE_FLOORF@
891 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
892 # undef floorf
893 # define floorf rpl_floorf
894 # endif
895 _GL_FUNCDECL_RPL (floorf, float, (float x));
896 _GL_CXXALIAS_RPL (floorf, float, (float x));
897 # else
898 # if !@HAVE_DECL_FLOORF@
899 # undef floorf
900 _GL_FUNCDECL_SYS (floorf, float, (float x));
901 # endif
902 _GL_CXXALIAS_SYS (floorf, float, (float x));
903 # endif
904 _GL_CXXALIASWARN (floorf);
905 #elif defined GNULIB_POSIXCHECK
906 # undef floorf
907 # if HAVE_RAW_DECL_FLOORF
908 _GL_WARN_ON_USE (floorf, "floorf is unportable - "
909 "use gnulib module floorf for portability");
910 # endif
911 #endif
913 #if @GNULIB_FLOOR@
914 # if @REPLACE_FLOOR@
915 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
916 # undef floor
917 # define floor rpl_floor
918 # endif
919 _GL_FUNCDECL_RPL (floor, double, (double x));
920 _GL_CXXALIAS_RPL (floor, double, (double x));
921 # else
922 _GL_CXXALIAS_SYS (floor, double, (double x));
923 # endif
924 # if __GLIBC__ >= 2
925 _GL_CXXALIASWARN1 (floor, double, (double x));
926 # endif
927 #endif
929 #if @GNULIB_FLOORL@
930 # if @REPLACE_FLOORL@
931 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
932 # undef floorl
933 # define floorl rpl_floorl
934 # endif
935 _GL_FUNCDECL_RPL (floorl, long double, (long double x));
936 _GL_CXXALIAS_RPL (floorl, long double, (long double x));
937 # else
938 # if !@HAVE_DECL_FLOORL@
939 # undef floorl
940 _GL_FUNCDECL_SYS (floorl, long double, (long double x));
941 # endif
942 _GL_CXXALIAS_SYS (floorl, long double, (long double x));
943 # endif
944 # if __GLIBC__ >= 2
945 _GL_CXXALIASWARN (floorl);
946 # endif
947 #elif defined GNULIB_POSIXCHECK
948 # undef floorl
949 # if HAVE_RAW_DECL_FLOORL
950 _GL_WARN_ON_USE (floorl, "floorl is unportable - "
951 "use gnulib module floorl for portability");
952 # endif
953 #endif
956 #if @GNULIB_FMAF@
957 # if @REPLACE_FMAF@
958 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
959 # undef fmaf
960 # define fmaf rpl_fmaf
961 # endif
962 _GL_FUNCDECL_RPL (fmaf, float, (float x, float y, float z));
963 _GL_CXXALIAS_RPL (fmaf, float, (float x, float y, float z));
964 # else
965 # if !@HAVE_FMAF@
966 # undef fmaf
967 _GL_FUNCDECL_SYS (fmaf, float, (float x, float y, float z));
968 # endif
969 _GL_CXXALIAS_SYS (fmaf, float, (float x, float y, float z));
970 # endif
971 _GL_CXXALIASWARN (fmaf);
972 #elif defined GNULIB_POSIXCHECK
973 # undef fmaf
974 # if HAVE_RAW_DECL_FMAF
975 _GL_WARN_ON_USE (fmaf, "fmaf is unportable - "
976 "use gnulib module fmaf for portability");
977 # endif
978 #endif
980 #if @GNULIB_FMA@
981 # if @REPLACE_FMA@
982 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
983 # undef fma
984 # define fma rpl_fma
985 # endif
986 _GL_FUNCDECL_RPL (fma, double, (double x, double y, double z));
987 _GL_CXXALIAS_RPL (fma, double, (double x, double y, double z));
988 # else
989 # if !@HAVE_FMA@
990 # undef fma
991 _GL_FUNCDECL_SYS (fma, double, (double x, double y, double z));
992 # endif
993 _GL_CXXALIAS_SYS (fma, double, (double x, double y, double z));
994 # endif
995 # if __GLIBC__ >= 2
996 _GL_CXXALIASWARN1 (fma, double, (double x, double y, double z));
997 # endif
998 #elif defined GNULIB_POSIXCHECK
999 # undef fma
1000 # if HAVE_RAW_DECL_FMA
1001 _GL_WARN_ON_USE (fma, "fma is unportable - "
1002 "use gnulib module fma for portability");
1003 # endif
1004 #endif
1006 #if @GNULIB_FMAL@
1007 # if @REPLACE_FMAL@
1008 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1009 # undef fmal
1010 # define fmal rpl_fmal
1011 # endif
1012 _GL_FUNCDECL_RPL (fmal, long double,
1013 (long double x, long double y, long double z));
1014 _GL_CXXALIAS_RPL (fmal, long double,
1015 (long double x, long double y, long double z));
1016 # else
1017 # if !@HAVE_FMAL@
1018 # undef fmal
1019 # if !(defined __cplusplus && defined _AIX)
1020 _GL_FUNCDECL_SYS (fmal, long double,
1021 (long double x, long double y, long double z));
1022 # endif
1023 # endif
1024 _GL_CXXALIAS_SYS (fmal, long double,
1025 (long double x, long double y, long double z));
1026 # endif
1027 # if __GLIBC__ >= 2
1028 _GL_CXXALIASWARN (fmal);
1029 # endif
1030 #elif defined GNULIB_POSIXCHECK
1031 # undef fmal
1032 # if HAVE_RAW_DECL_FMAL
1033 _GL_WARN_ON_USE (fmal, "fmal is unportable - "
1034 "use gnulib module fmal for portability");
1035 # endif
1036 #endif
1039 #if @GNULIB_FMODF@
1040 # if @REPLACE_FMODF@
1041 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1042 # undef fmodf
1043 # define fmodf rpl_fmodf
1044 # endif
1045 _GL_FUNCDECL_RPL (fmodf, float, (float x, float y));
1046 _GL_CXXALIAS_RPL (fmodf, float, (float x, float y));
1047 # else
1048 # if !@HAVE_FMODF@
1049 # undef fmodf
1050 _GL_FUNCDECL_SYS (fmodf, float, (float x, float y));
1051 # endif
1052 _GL_CXXALIAS_SYS (fmodf, float, (float x, float y));
1053 # endif
1054 _GL_CXXALIASWARN (fmodf);
1055 #elif defined GNULIB_POSIXCHECK
1056 # undef fmodf
1057 # if HAVE_RAW_DECL_FMODF
1058 _GL_WARN_ON_USE (fmodf, "fmodf is unportable - "
1059 "use gnulib module fmodf for portability");
1060 # endif
1061 #endif
1063 #if @GNULIB_FMOD@
1064 # if @REPLACE_FMOD@
1065 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1066 # undef fmod
1067 # define fmod rpl_fmod
1068 # endif
1069 _GL_FUNCDECL_RPL (fmod, double, (double x, double y));
1070 _GL_CXXALIAS_RPL (fmod, double, (double x, double y));
1071 # else
1072 _GL_CXXALIAS_SYS (fmod, double, (double x, double y));
1073 # endif
1074 # if __GLIBC__ >= 2
1075 _GL_CXXALIASWARN1 (fmod, double, (double x, double y));
1076 # endif
1077 #elif defined GNULIB_POSIXCHECK
1078 # undef fmod
1079 # if HAVE_RAW_DECL_FMOD
1080 _GL_WARN_ON_USE (fmod, "fmod has portability problems - "
1081 "use gnulib module fmod for portability");
1082 # endif
1083 #endif
1085 #if @GNULIB_FMODL@
1086 # if @REPLACE_FMODL@
1087 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1088 # undef fmodl
1089 # define fmodl rpl_fmodl
1090 # endif
1091 _GL_FUNCDECL_RPL (fmodl, long double, (long double x, long double y));
1092 _GL_CXXALIAS_RPL (fmodl, long double, (long double x, long double y));
1093 # else
1094 # if !@HAVE_FMODL@
1095 # undef fmodl
1096 _GL_FUNCDECL_SYS (fmodl, long double, (long double x, long double y));
1097 # endif
1098 _GL_CXXALIAS_SYS (fmodl, long double, (long double x, long double y));
1099 # endif
1100 # if __GLIBC__ >= 2
1101 _GL_CXXALIASWARN (fmodl);
1102 # endif
1103 #elif defined GNULIB_POSIXCHECK
1104 # undef fmodl
1105 # if HAVE_RAW_DECL_FMODL
1106 _GL_WARN_ON_USE (fmodl, "fmodl is unportable - "
1107 "use gnulib module fmodl for portability");
1108 # endif
1109 #endif
1112 /* Write x as
1113 x = mantissa * 2^exp
1114 where
1115 If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1116 If x is zero: mantissa = x, exp = 0.
1117 If x is infinite or NaN: mantissa = x, exp unspecified.
1118 Store exp in *EXPPTR and return mantissa. */
1119 #if @GNULIB_FREXPF@
1120 # if @REPLACE_FREXPF@
1121 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1122 # undef frexpf
1123 # define frexpf rpl_frexpf
1124 # endif
1125 _GL_FUNCDECL_RPL (frexpf, float, (float x, int *expptr) _GL_ARG_NONNULL ((2)));
1126 _GL_CXXALIAS_RPL (frexpf, float, (float x, int *expptr));
1127 # else
1128 # if !@HAVE_FREXPF@
1129 # undef frexpf
1130 _GL_FUNCDECL_SYS (frexpf, float, (float x, int *expptr) _GL_ARG_NONNULL ((2)));
1131 # endif
1132 _GL_CXXALIAS_SYS (frexpf, float, (float x, int *expptr));
1133 # endif
1134 # if __GLIBC__ >= 2
1135 _GL_CXXALIASWARN (frexpf);
1136 # endif
1137 #elif defined GNULIB_POSIXCHECK
1138 # undef frexpf
1139 # if HAVE_RAW_DECL_FREXPF
1140 _GL_WARN_ON_USE (frexpf, "frexpf is unportable - "
1141 "use gnulib module frexpf for portability");
1142 # endif
1143 #endif
1145 /* Write x as
1146 x = mantissa * 2^exp
1147 where
1148 If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1149 If x is zero: mantissa = x, exp = 0.
1150 If x is infinite or NaN: mantissa = x, exp unspecified.
1151 Store exp in *EXPPTR and return mantissa. */
1152 #if @GNULIB_FREXP@
1153 # if @REPLACE_FREXP@
1154 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1155 # undef frexp
1156 # define frexp rpl_frexp
1157 # endif
1158 _GL_FUNCDECL_RPL (frexp, double, (double x, int *expptr) _GL_ARG_NONNULL ((2)));
1159 _GL_CXXALIAS_RPL (frexp, double, (double x, int *expptr));
1160 # else
1161 _GL_CXXALIAS_SYS (frexp, double, (double x, int *expptr));
1162 # endif
1163 # if __GLIBC__ >= 2
1164 _GL_CXXALIASWARN1 (frexp, double, (double x, int *expptr));
1165 # endif
1166 #elif defined GNULIB_POSIXCHECK
1167 # undef frexp
1168 /* Assume frexp is always declared. */
1169 _GL_WARN_ON_USE (frexp, "frexp is unportable - "
1170 "use gnulib module frexp for portability");
1171 #endif
1173 /* Write x as
1174 x = mantissa * 2^exp
1175 where
1176 If x finite and nonzero: 0.5 <= |mantissa| < 1.0.
1177 If x is zero: mantissa = x, exp = 0.
1178 If x is infinite or NaN: mantissa = x, exp unspecified.
1179 Store exp in *EXPPTR and return mantissa. */
1180 #if @GNULIB_FREXPL@ && @REPLACE_FREXPL@
1181 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1182 # undef frexpl
1183 # define frexpl rpl_frexpl
1184 # endif
1185 _GL_FUNCDECL_RPL (frexpl, long double,
1186 (long double x, int *expptr) _GL_ARG_NONNULL ((2)));
1187 _GL_CXXALIAS_RPL (frexpl, long double, (long double x, int *expptr));
1188 #else
1189 # if !@HAVE_DECL_FREXPL@
1190 _GL_FUNCDECL_SYS (frexpl, long double,
1191 (long double x, int *expptr) _GL_ARG_NONNULL ((2)));
1192 # endif
1193 # if @GNULIB_FREXPL@
1194 _GL_CXXALIAS_SYS (frexpl, long double, (long double x, int *expptr));
1195 # endif
1196 #endif
1197 #if @GNULIB_FREXPL@ && !(@REPLACE_FREXPL@ && !@HAVE_DECL_FREXPL@)
1198 # if __GLIBC__ >= 2
1199 _GL_CXXALIASWARN (frexpl);
1200 # endif
1201 #endif
1202 #if !@GNULIB_FREXPL@ && defined GNULIB_POSIXCHECK
1203 # undef frexpl
1204 # if HAVE_RAW_DECL_FREXPL
1205 _GL_WARN_ON_USE (frexpl, "frexpl is unportable - "
1206 "use gnulib module frexpl for portability");
1207 # endif
1208 #endif
1211 /* Return sqrt(x^2+y^2). */
1212 #if @GNULIB_HYPOTF@
1213 # if @REPLACE_HYPOTF@
1214 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1215 # undef hypotf
1216 # define hypotf rpl_hypotf
1217 # endif
1218 _GL_FUNCDECL_RPL (hypotf, float, (float x, float y));
1219 _GL_CXXALIAS_RPL (hypotf, float, (float x, float y));
1220 # else
1221 # if !@HAVE_HYPOTF@
1222 _GL_FUNCDECL_SYS (hypotf, float, (float x, float y));
1223 # endif
1224 _GL_CXXALIAS_SYS (hypotf, float, (float x, float y));
1225 # endif
1226 # if __GLIBC__ >= 2
1227 _GL_CXXALIASWARN (hypotf);
1228 # endif
1229 #elif defined GNULIB_POSIXCHECK
1230 # undef hypotf
1231 # if HAVE_RAW_DECL_HYPOTF
1232 _GL_WARN_ON_USE (hypotf, "hypotf is unportable - "
1233 "use gnulib module hypotf for portability");
1234 # endif
1235 #endif
1237 /* Return sqrt(x^2+y^2). */
1238 #if @GNULIB_HYPOT@
1239 # if @REPLACE_HYPOT@
1240 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1241 # undef hypot
1242 # define hypot rpl_hypot
1243 # endif
1244 _GL_FUNCDECL_RPL (hypot, double, (double x, double y));
1245 _GL_CXXALIAS_RPL (hypot, double, (double x, double y));
1246 # else
1247 _GL_CXXALIAS_SYS (hypot, double, (double x, double y));
1248 # endif
1249 # if __GLIBC__ >= 2
1250 _GL_CXXALIASWARN1 (hypot, double, (double x, double y));
1251 # endif
1252 #elif defined GNULIB_POSIXCHECK
1253 # undef hypot
1254 # if HAVE_RAW_DECL_HYPOT
1255 _GL_WARN_ON_USE (hypotf, "hypot has portability problems - "
1256 "use gnulib module hypot for portability");
1257 # endif
1258 #endif
1260 /* Return sqrt(x^2+y^2). */
1261 #if @GNULIB_HYPOTL@
1262 # if @REPLACE_HYPOTL@
1263 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1264 # undef hypotl
1265 # define hypotl rpl_hypotl
1266 # endif
1267 _GL_FUNCDECL_RPL (hypotl, long double, (long double x, long double y));
1268 _GL_CXXALIAS_RPL (hypotl, long double, (long double x, long double y));
1269 # else
1270 # if !@HAVE_HYPOTL@
1271 _GL_FUNCDECL_SYS (hypotl, long double, (long double x, long double y));
1272 # endif
1273 _GL_CXXALIAS_SYS (hypotl, long double, (long double x, long double y));
1274 # endif
1275 # if __GLIBC__ >= 2
1276 _GL_CXXALIASWARN (hypotl);
1277 # endif
1278 #elif defined GNULIB_POSIXCHECK
1279 # undef hypotl
1280 # if HAVE_RAW_DECL_HYPOTL
1281 _GL_WARN_ON_USE (hypotl, "hypotl is unportable - "
1282 "use gnulib module hypotl for portability");
1283 # endif
1284 #endif
1287 #if @GNULIB_ILOGBF@
1288 # if @REPLACE_ILOGBF@
1289 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1290 # undef ilogbf
1291 # define ilogbf rpl_ilogbf
1292 # endif
1293 _GL_FUNCDECL_RPL (ilogbf, int, (float x));
1294 _GL_CXXALIAS_RPL (ilogbf, int, (float x));
1295 # else
1296 # if !@HAVE_ILOGBF@
1297 _GL_FUNCDECL_SYS (ilogbf, int, (float x));
1298 # endif
1299 _GL_CXXALIAS_SYS (ilogbf, int, (float x));
1300 # endif
1301 _GL_CXXALIASWARN (ilogbf);
1302 #elif defined GNULIB_POSIXCHECK
1303 # undef ilogbf
1304 # if HAVE_RAW_DECL_ILOGBF
1305 _GL_WARN_ON_USE (ilogbf, "ilogbf is unportable - "
1306 "use gnulib module ilogbf for portability");
1307 # endif
1308 #endif
1310 #if @GNULIB_ILOGB@
1311 # if @REPLACE_ILOGB@
1312 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1313 # undef ilogb
1314 # define ilogb rpl_ilogb
1315 # endif
1316 _GL_FUNCDECL_RPL (ilogb, int, (double x));
1317 _GL_CXXALIAS_RPL (ilogb, int, (double x));
1318 # else
1319 # if !@HAVE_ILOGB@
1320 _GL_FUNCDECL_SYS (ilogb, int, (double x));
1321 # endif
1322 _GL_CXXALIAS_SYS (ilogb, int, (double x));
1323 # endif
1324 # if __GLIBC__ >= 2
1325 _GL_CXXALIASWARN1 (ilogb, int, (double x));
1326 # endif
1327 #elif defined GNULIB_POSIXCHECK
1328 # undef ilogb
1329 # if HAVE_RAW_DECL_ILOGB
1330 _GL_WARN_ON_USE (ilogb, "ilogb is unportable - "
1331 "use gnulib module ilogb for portability");
1332 # endif
1333 #endif
1335 #if @GNULIB_ILOGBL@
1336 # if @REPLACE_ILOGBL@
1337 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1338 # undef ilogbl
1339 # define ilogbl rpl_ilogbl
1340 # endif
1341 _GL_FUNCDECL_RPL (ilogbl, int, (long double x));
1342 _GL_CXXALIAS_RPL (ilogbl, int, (long double x));
1343 # else
1344 # if !@HAVE_ILOGBL@
1345 # undef ilogbl
1346 _GL_FUNCDECL_SYS (ilogbl, int, (long double x));
1347 # endif
1348 _GL_CXXALIAS_SYS (ilogbl, int, (long double x));
1349 # endif
1350 # if __GLIBC__ >= 2
1351 _GL_CXXALIASWARN (ilogbl);
1352 # endif
1353 #elif defined GNULIB_POSIXCHECK
1354 # undef ilogbl
1355 # if HAVE_RAW_DECL_ILOGBL
1356 _GL_WARN_ON_USE (ilogbl, "ilogbl is unportable - "
1357 "use gnulib module ilogbl for portability");
1358 # endif
1359 #endif
1362 #if @GNULIB_MDA_J0@
1363 /* On native Windows, map 'j0' to '_j0', so that -loldnames is not
1364 required. In C++ with GNULIB_NAMESPACE, avoid differences between
1365 platforms by defining GNULIB_NAMESPACE::j0 always. */
1366 # if defined _WIN32 && !defined __CYGWIN__
1367 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1368 # undef j0
1369 # define j0 _j0
1370 # endif
1371 _GL_CXXALIAS_MDA (j0, double, (double x));
1372 # else
1373 _GL_CXXALIAS_SYS (j0, double, (double x));
1374 # endif
1375 _GL_CXXALIASWARN (j0);
1376 #endif
1378 #if @GNULIB_MDA_J1@
1379 /* On native Windows, map 'j1' to '_j1', so that -loldnames is not
1380 required. In C++ with GNULIB_NAMESPACE, avoid differences between
1381 platforms by defining GNULIB_NAMESPACE::j1 always. */
1382 # if defined _WIN32 && !defined __CYGWIN__
1383 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1384 # undef j1
1385 # define j1 _j1
1386 # endif
1387 _GL_CXXALIAS_MDA (j1, double, (double x));
1388 # else
1389 _GL_CXXALIAS_SYS (j1, double, (double x));
1390 # endif
1391 _GL_CXXALIASWARN (j1);
1392 #endif
1394 #if @GNULIB_MDA_JN@
1395 /* On native Windows, map 'jn' to '_jn', so that -loldnames is not
1396 required. In C++ with GNULIB_NAMESPACE, avoid differences between
1397 platforms by defining GNULIB_NAMESPACE::jn always. */
1398 # if defined _WIN32 && !defined __CYGWIN__
1399 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1400 # undef jn
1401 # define jn _jn
1402 # endif
1403 _GL_CXXALIAS_MDA (jn, double, (int n, double x));
1404 # else
1405 _GL_CXXALIAS_SYS (jn, double, (int n, double x));
1406 # endif
1407 _GL_CXXALIASWARN (jn);
1408 #endif
1411 /* Return x * 2^exp. */
1412 #if @GNULIB_LDEXPF@
1413 # if !@HAVE_LDEXPF@
1414 # undef ldexpf
1415 _GL_FUNCDECL_SYS (ldexpf, float, (float x, int exp));
1416 # endif
1417 _GL_CXXALIAS_SYS (ldexpf, float, (float x, int exp));
1418 # if __GLIBC__ >= 2
1419 _GL_CXXALIASWARN (ldexpf);
1420 # endif
1421 #elif defined GNULIB_POSIXCHECK
1422 # undef ldexpf
1423 # if HAVE_RAW_DECL_LDEXPF
1424 _GL_WARN_ON_USE (ldexpf, "ldexpf is unportable - "
1425 "use gnulib module ldexpf for portability");
1426 # endif
1427 #endif
1429 /* Return x * 2^exp. */
1430 #if @GNULIB_LDEXPL@ && @REPLACE_LDEXPL@
1431 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1432 # undef ldexpl
1433 # define ldexpl rpl_ldexpl
1434 # endif
1435 _GL_FUNCDECL_RPL (ldexpl, long double, (long double x, int exp));
1436 _GL_CXXALIAS_RPL (ldexpl, long double, (long double x, int exp));
1437 #else
1438 # if !@HAVE_DECL_LDEXPL@
1439 _GL_FUNCDECL_SYS (ldexpl, long double, (long double x, int exp));
1440 # endif
1441 # if @GNULIB_LDEXPL@
1442 _GL_CXXALIAS_SYS (ldexpl, long double, (long double x, int exp));
1443 # endif
1444 #endif
1445 #if @GNULIB_LDEXPL@
1446 # if __GLIBC__ >= 2
1447 _GL_CXXALIASWARN (ldexpl);
1448 # endif
1449 #endif
1450 #if !@GNULIB_LDEXPL@ && defined GNULIB_POSIXCHECK
1451 # undef ldexpl
1452 # if HAVE_RAW_DECL_LDEXPL
1453 _GL_WARN_ON_USE (ldexpl, "ldexpl is unportable - "
1454 "use gnulib module ldexpl for portability");
1455 # endif
1456 #endif
1459 #if @GNULIB_LOGF@
1460 # if @REPLACE_LOGF@
1461 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1462 # undef logf
1463 # define logf rpl_logf
1464 # endif
1465 _GL_FUNCDECL_RPL (logf, float, (float x));
1466 _GL_CXXALIAS_RPL (logf, float, (float x));
1467 # else
1468 # if !@HAVE_LOGF@
1469 # undef logf
1470 _GL_FUNCDECL_SYS (logf, float, (float x));
1471 # endif
1472 _GL_CXXALIAS_SYS (logf, float, (float x));
1473 # endif
1474 _GL_CXXALIASWARN (logf);
1475 #elif defined GNULIB_POSIXCHECK
1476 # undef logf
1477 # if HAVE_RAW_DECL_LOGF
1478 _GL_WARN_ON_USE (logf, "logf is unportable - "
1479 "use gnulib module logf for portability");
1480 # endif
1481 #endif
1483 #if @GNULIB_LOG@
1484 # if @REPLACE_LOG@
1485 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1486 # undef log
1487 # define log rpl_log
1488 # endif
1489 _GL_FUNCDECL_RPL (log, double, (double x));
1490 _GL_CXXALIAS_RPL (log, double, (double x));
1491 # else
1492 _GL_CXXALIAS_SYS (log, double, (double x));
1493 # endif
1494 # if __GLIBC__ >= 2
1495 _GL_CXXALIASWARN1 (log, double, (double x));
1496 # endif
1497 #elif defined GNULIB_POSIXCHECK
1498 # undef log
1499 # if HAVE_RAW_DECL_LOG
1500 _GL_WARN_ON_USE (log, "log has portability problems - "
1501 "use gnulib module log for portability");
1502 # endif
1503 #endif
1505 #if @GNULIB_LOGL@
1506 # if @REPLACE_LOGL@
1507 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1508 # undef logl
1509 # define logl rpl_logl
1510 # endif
1511 _GL_FUNCDECL_RPL (logl, long double, (long double x));
1512 _GL_CXXALIAS_RPL (logl, long double, (long double x));
1513 # else
1514 # if !@HAVE_LOGL@ || !@HAVE_DECL_LOGL@
1515 # undef logl
1516 _GL_FUNCDECL_SYS (logl, long double, (long double x));
1517 # endif
1518 _GL_CXXALIAS_SYS (logl, long double, (long double x));
1519 # endif
1520 # if __GLIBC__ >= 2
1521 _GL_CXXALIASWARN (logl);
1522 # endif
1523 #elif defined GNULIB_POSIXCHECK
1524 # undef logl
1525 # if HAVE_RAW_DECL_LOGL
1526 _GL_WARN_ON_USE (logl, "logl is unportable - "
1527 "use gnulib module logl for portability");
1528 # endif
1529 #endif
1532 #if @GNULIB_LOG10F@
1533 # if @REPLACE_LOG10F@
1534 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1535 # undef log10f
1536 # define log10f rpl_log10f
1537 # endif
1538 _GL_FUNCDECL_RPL (log10f, float, (float x));
1539 _GL_CXXALIAS_RPL (log10f, float, (float x));
1540 # else
1541 # if !@HAVE_LOG10F@
1542 # undef log10f
1543 _GL_FUNCDECL_SYS (log10f, float, (float x));
1544 # endif
1545 _GL_CXXALIAS_SYS (log10f, float, (float x));
1546 # endif
1547 _GL_CXXALIASWARN (log10f);
1548 #elif defined GNULIB_POSIXCHECK
1549 # undef log10f
1550 # if HAVE_RAW_DECL_LOG10F
1551 _GL_WARN_ON_USE (log10f, "log10f is unportable - "
1552 "use gnulib module log10f for portability");
1553 # endif
1554 #endif
1556 #if @GNULIB_LOG10@
1557 # if @REPLACE_LOG10@
1558 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1559 # undef log10
1560 # define log10 rpl_log10
1561 # endif
1562 _GL_FUNCDECL_RPL (log10, double, (double x));
1563 _GL_CXXALIAS_RPL (log10, double, (double x));
1564 # else
1565 _GL_CXXALIAS_SYS (log10, double, (double x));
1566 # endif
1567 # if __GLIBC__ >= 2
1568 _GL_CXXALIASWARN1 (log10, double, (double x));
1569 # endif
1570 #elif defined GNULIB_POSIXCHECK
1571 # undef log10
1572 # if HAVE_RAW_DECL_LOG10
1573 _GL_WARN_ON_USE (log10, "log10 has portability problems - "
1574 "use gnulib module log10 for portability");
1575 # endif
1576 #endif
1578 #if @GNULIB_LOG10L@
1579 # if @REPLACE_LOG10L@
1580 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1581 # undef log10l
1582 # define log10l rpl_log10l
1583 # endif
1584 _GL_FUNCDECL_RPL (log10l, long double, (long double x));
1585 _GL_CXXALIAS_RPL (log10l, long double, (long double x));
1586 # else
1587 # if !@HAVE_LOG10L@ || !@HAVE_DECL_LOG10L@
1588 # undef log10l
1589 _GL_FUNCDECL_SYS (log10l, long double, (long double x));
1590 # endif
1591 _GL_CXXALIAS_SYS (log10l, long double, (long double x));
1592 # endif
1593 # if __GLIBC__ >= 2
1594 _GL_CXXALIASWARN (log10l);
1595 # endif
1596 #elif defined GNULIB_POSIXCHECK
1597 # undef log10l
1598 # if HAVE_RAW_DECL_LOG10L
1599 _GL_WARN_ON_USE (log10l, "log10l is unportable - "
1600 "use gnulib module log10l for portability");
1601 # endif
1602 #endif
1605 #if @GNULIB_LOG1PF@
1606 # if @REPLACE_LOG1PF@
1607 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1608 # undef log1pf
1609 # define log1pf rpl_log1pf
1610 # endif
1611 _GL_FUNCDECL_RPL (log1pf, float, (float x));
1612 _GL_CXXALIAS_RPL (log1pf, float, (float x));
1613 # else
1614 # if !@HAVE_LOG1PF@
1615 _GL_FUNCDECL_SYS (log1pf, float, (float x));
1616 # endif
1617 _GL_CXXALIAS_SYS (log1pf, float, (float x));
1618 # endif
1619 _GL_CXXALIASWARN (log1pf);
1620 #elif defined GNULIB_POSIXCHECK
1621 # undef log1pf
1622 # if HAVE_RAW_DECL_LOG1PF
1623 _GL_WARN_ON_USE (log1pf, "log1pf is unportable - "
1624 "use gnulib module log1pf for portability");
1625 # endif
1626 #endif
1628 #if @GNULIB_LOG1P@
1629 # if @REPLACE_LOG1P@
1630 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1631 # undef log1p
1632 # define log1p rpl_log1p
1633 # endif
1634 _GL_FUNCDECL_RPL (log1p, double, (double x));
1635 _GL_CXXALIAS_RPL (log1p, double, (double x));
1636 # else
1637 # if !@HAVE_LOG1P@
1638 _GL_FUNCDECL_SYS (log1p, double, (double x));
1639 # endif
1640 _GL_CXXALIAS_SYS (log1p, double, (double x));
1641 # endif
1642 # if __GLIBC__ >= 2
1643 _GL_CXXALIASWARN1 (log1p, double, (double x));
1644 # endif
1645 #elif defined GNULIB_POSIXCHECK
1646 # undef log1p
1647 # if HAVE_RAW_DECL_LOG1P
1648 _GL_WARN_ON_USE (log1p, "log1p has portability problems - "
1649 "use gnulib module log1p for portability");
1650 # endif
1651 #endif
1653 #if @GNULIB_LOG1PL@
1654 # if @REPLACE_LOG1PL@
1655 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1656 # undef log1pl
1657 # define log1pl rpl_log1pl
1658 # endif
1659 _GL_FUNCDECL_RPL (log1pl, long double, (long double x));
1660 _GL_CXXALIAS_RPL (log1pl, long double, (long double x));
1661 # else
1662 # if !@HAVE_LOG1PL@
1663 _GL_FUNCDECL_SYS (log1pl, long double, (long double x));
1664 # endif
1665 _GL_CXXALIAS_SYS (log1pl, long double, (long double x));
1666 # endif
1667 # if __GLIBC__ >= 2
1668 _GL_CXXALIASWARN (log1pl);
1669 # endif
1670 #elif defined GNULIB_POSIXCHECK
1671 # undef log1pl
1672 # if HAVE_RAW_DECL_LOG1PL
1673 _GL_WARN_ON_USE (log1pl, "log1pl has portability problems - "
1674 "use gnulib module log1pl for portability");
1675 # endif
1676 #endif
1679 #if @GNULIB_LOG2F@
1680 # if @REPLACE_LOG2F@
1681 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1682 # undef log2f
1683 # define log2f rpl_log2f
1684 # endif
1685 _GL_FUNCDECL_RPL (log2f, float, (float x));
1686 _GL_CXXALIAS_RPL (log2f, float, (float x));
1687 # else
1688 # if !@HAVE_DECL_LOG2F@
1689 # undef log2f
1690 _GL_FUNCDECL_SYS (log2f, float, (float x));
1691 # endif
1692 _GL_CXXALIAS_SYS (log2f, float, (float x));
1693 # endif
1694 _GL_CXXALIASWARN (log2f);
1695 #elif defined GNULIB_POSIXCHECK
1696 # undef log2f
1697 # if HAVE_RAW_DECL_LOG2F
1698 _GL_WARN_ON_USE (log2f, "log2f is unportable - "
1699 "use gnulib module log2f for portability");
1700 # endif
1701 #endif
1703 #if @GNULIB_LOG2@
1704 # if @REPLACE_LOG2@
1705 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1706 # undef log2
1707 # define log2 rpl_log2
1708 # endif
1709 _GL_FUNCDECL_RPL (log2, double, (double x));
1710 _GL_CXXALIAS_RPL (log2, double, (double x));
1711 # else
1712 # if !@HAVE_DECL_LOG2@
1713 # undef log2
1714 _GL_FUNCDECL_SYS (log2, double, (double x));
1715 # endif
1716 _GL_CXXALIAS_SYS (log2, double, (double x));
1717 # endif
1718 # if __GLIBC__ >= 2
1719 _GL_CXXALIASWARN1 (log2, double, (double x));
1720 # endif
1721 #elif defined GNULIB_POSIXCHECK
1722 # undef log2
1723 # if HAVE_RAW_DECL_LOG2
1724 _GL_WARN_ON_USE (log2, "log2 is unportable - "
1725 "use gnulib module log2 for portability");
1726 # endif
1727 #endif
1729 #if @GNULIB_LOG2L@
1730 # if @REPLACE_LOG2L@
1731 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1732 # undef log2l
1733 # define log2l rpl_log2l
1734 # endif
1735 _GL_FUNCDECL_RPL (log2l, long double, (long double x));
1736 _GL_CXXALIAS_RPL (log2l, long double, (long double x));
1737 # else
1738 # if !@HAVE_DECL_LOG2L@
1739 _GL_FUNCDECL_SYS (log2l, long double, (long double x));
1740 # endif
1741 _GL_CXXALIAS_SYS (log2l, long double, (long double x));
1742 # endif
1743 # if __GLIBC__ >= 2
1744 _GL_CXXALIASWARN (log2l);
1745 # endif
1746 #elif defined GNULIB_POSIXCHECK
1747 # undef log2l
1748 # if HAVE_RAW_DECL_LOG2L
1749 _GL_WARN_ON_USE (log2l, "log2l is unportable - "
1750 "use gnulib module log2l for portability");
1751 # endif
1752 #endif
1755 #if @GNULIB_LOGBF@
1756 # if @REPLACE_LOGBF@
1757 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1758 # undef logbf
1759 # define logbf rpl_logbf
1760 # endif
1761 _GL_FUNCDECL_RPL (logbf, float, (float x));
1762 _GL_CXXALIAS_RPL (logbf, float, (float x));
1763 # else
1764 # if !@HAVE_LOGBF@
1765 _GL_FUNCDECL_SYS (logbf, float, (float x));
1766 # endif
1767 _GL_CXXALIAS_SYS (logbf, float, (float x));
1768 # endif
1769 _GL_CXXALIASWARN (logbf);
1770 #elif defined GNULIB_POSIXCHECK
1771 # undef logbf
1772 # if HAVE_RAW_DECL_LOGBF
1773 _GL_WARN_ON_USE (logbf, "logbf is unportable - "
1774 "use gnulib module logbf for portability");
1775 # endif
1776 #endif
1778 #if @GNULIB_LOGB@
1779 # if @REPLACE_LOGB@
1780 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1781 # undef logb
1782 # define logb rpl_logb
1783 # endif
1784 _GL_FUNCDECL_RPL (logb, double, (double x));
1785 _GL_CXXALIAS_RPL (logb, double, (double x));
1786 # else
1787 # if !@HAVE_DECL_LOGB@
1788 _GL_FUNCDECL_SYS (logb, double, (double x));
1789 # endif
1790 _GL_CXXALIAS_SYS (logb, double, (double x));
1791 # endif
1792 # if __GLIBC__ >= 2
1793 _GL_CXXALIASWARN1 (logb, double, (double x));
1794 # endif
1795 #elif defined GNULIB_POSIXCHECK
1796 # undef logb
1797 # if HAVE_RAW_DECL_LOGB
1798 _GL_WARN_ON_USE (logb, "logb is unportable - "
1799 "use gnulib module logb for portability");
1800 # endif
1801 #endif
1803 #if @GNULIB_LOGBL@
1804 # if @REPLACE_LOGBL@
1805 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1806 # undef logbl
1807 # define logbl rpl_logbl
1808 # endif
1809 _GL_FUNCDECL_RPL (logbl, long double, (long double x));
1810 _GL_CXXALIAS_RPL (logbl, long double, (long double x));
1811 # else
1812 # if !@HAVE_LOGBL@
1813 _GL_FUNCDECL_SYS (logbl, long double, (long double x));
1814 # endif
1815 _GL_CXXALIAS_SYS (logbl, long double, (long double x));
1816 # endif
1817 # if __GLIBC__ >= 2
1818 _GL_CXXALIASWARN (logbl);
1819 # endif
1820 #elif defined GNULIB_POSIXCHECK
1821 # undef logbl
1822 # if HAVE_RAW_DECL_LOGBL
1823 _GL_WARN_ON_USE (logbl, "logbl is unportable - "
1824 "use gnulib module logbl for portability");
1825 # endif
1826 #endif
1829 #if @GNULIB_MODFF@
1830 # if @REPLACE_MODFF@
1831 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1832 # undef modff
1833 # define modff rpl_modff
1834 # endif
1835 _GL_FUNCDECL_RPL (modff, float, (float x, float *iptr) _GL_ARG_NONNULL ((2)));
1836 _GL_CXXALIAS_RPL (modff, float, (float x, float *iptr));
1837 # else
1838 # if !@HAVE_MODFF@
1839 # undef modff
1840 _GL_FUNCDECL_SYS (modff, float, (float x, float *iptr) _GL_ARG_NONNULL ((2)));
1841 # endif
1842 _GL_CXXALIAS_SYS (modff, float, (float x, float *iptr));
1843 # endif
1844 _GL_CXXALIASWARN (modff);
1845 #elif defined GNULIB_POSIXCHECK
1846 # undef modff
1847 # if HAVE_RAW_DECL_MODFF
1848 _GL_WARN_ON_USE (modff, "modff is unportable - "
1849 "use gnulib module modff for portability");
1850 # endif
1851 #endif
1853 #if @GNULIB_MODF@
1854 # if @REPLACE_MODF@
1855 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1856 # undef modf
1857 # define modf rpl_modf
1858 # endif
1859 _GL_FUNCDECL_RPL (modf, double, (double x, double *iptr) _GL_ARG_NONNULL ((2)));
1860 _GL_CXXALIAS_RPL (modf, double, (double x, double *iptr));
1861 # else
1862 _GL_CXXALIAS_SYS (modf, double, (double x, double *iptr));
1863 # endif
1864 # if __GLIBC__ >= 2
1865 _GL_CXXALIASWARN1 (modf, double, (double x, double *iptr));
1866 # endif
1867 #elif defined GNULIB_POSIXCHECK
1868 # undef modf
1869 # if HAVE_RAW_DECL_MODF
1870 _GL_WARN_ON_USE (modf, "modf has portability problems - "
1871 "use gnulib module modf for portability");
1872 # endif
1873 #endif
1875 #if @GNULIB_MODFL@
1876 # if @REPLACE_MODFL@
1877 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1878 # undef modfl
1879 # define modfl rpl_modfl
1880 # endif
1881 _GL_FUNCDECL_RPL (modfl, long double, (long double x, long double *iptr)
1882 _GL_ARG_NONNULL ((2)));
1883 _GL_CXXALIAS_RPL (modfl, long double, (long double x, long double *iptr));
1884 # else
1885 # if !@HAVE_MODFL@
1886 # undef modfl
1887 _GL_FUNCDECL_SYS (modfl, long double, (long double x, long double *iptr)
1888 _GL_ARG_NONNULL ((2)));
1889 # endif
1890 _GL_CXXALIAS_SYS (modfl, long double, (long double x, long double *iptr));
1891 # endif
1892 # if __GLIBC__ >= 2
1893 _GL_CXXALIASWARN (modfl);
1894 # endif
1895 #elif defined GNULIB_POSIXCHECK
1896 # undef modfl
1897 # if HAVE_RAW_DECL_MODFL
1898 _GL_WARN_ON_USE (modfl, "modfl is unportable - "
1899 "use gnulib module modfl for portability");
1900 # endif
1901 #endif
1904 #if @GNULIB_POWF@
1905 # if !@HAVE_POWF@
1906 # undef powf
1907 _GL_FUNCDECL_SYS (powf, float, (float x, float y));
1908 # endif
1909 _GL_CXXALIAS_SYS (powf, float, (float x, float y));
1910 _GL_CXXALIASWARN (powf);
1911 #elif defined GNULIB_POSIXCHECK
1912 # undef powf
1913 # if HAVE_RAW_DECL_POWF
1914 _GL_WARN_ON_USE (powf, "powf is unportable - "
1915 "use gnulib module powf for portability");
1916 # endif
1917 #endif
1920 #if @GNULIB_REMAINDERF@
1921 # if @REPLACE_REMAINDERF@
1922 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1923 # undef remainderf
1924 # define remainderf rpl_remainderf
1925 # endif
1926 _GL_FUNCDECL_RPL (remainderf, float, (float x, float y));
1927 _GL_CXXALIAS_RPL (remainderf, float, (float x, float y));
1928 # else
1929 # if !@HAVE_REMAINDERF@
1930 _GL_FUNCDECL_SYS (remainderf, float, (float x, float y));
1931 # endif
1932 _GL_CXXALIAS_SYS (remainderf, float, (float x, float y));
1933 # endif
1934 _GL_CXXALIASWARN (remainderf);
1935 #elif defined GNULIB_POSIXCHECK
1936 # undef remainderf
1937 # if HAVE_RAW_DECL_REMAINDERF
1938 _GL_WARN_ON_USE (remainderf, "remainderf is unportable - "
1939 "use gnulib module remainderf for portability");
1940 # endif
1941 #endif
1943 #if @GNULIB_REMAINDER@
1944 # if @REPLACE_REMAINDER@
1945 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1946 # undef remainder
1947 # define remainder rpl_remainder
1948 # endif
1949 _GL_FUNCDECL_RPL (remainder, double, (double x, double y));
1950 _GL_CXXALIAS_RPL (remainder, double, (double x, double y));
1951 # else
1952 # if !@HAVE_REMAINDER@ || !@HAVE_DECL_REMAINDER@
1953 _GL_FUNCDECL_SYS (remainder, double, (double x, double y));
1954 # endif
1955 _GL_CXXALIAS_SYS (remainder, double, (double x, double y));
1956 # endif
1957 # if __GLIBC__ >= 2
1958 _GL_CXXALIASWARN1 (remainder, double, (double x, double y));
1959 # endif
1960 #elif defined GNULIB_POSIXCHECK
1961 # undef remainder
1962 # if HAVE_RAW_DECL_REMAINDER
1963 _GL_WARN_ON_USE (remainder, "remainder is unportable - "
1964 "use gnulib module remainder for portability");
1965 # endif
1966 #endif
1968 #if @GNULIB_REMAINDERL@
1969 # if @REPLACE_REMAINDERL@
1970 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
1971 # undef remainderl
1972 # define remainderl rpl_remainderl
1973 # endif
1974 _GL_FUNCDECL_RPL (remainderl, long double, (long double x, long double y));
1975 _GL_CXXALIAS_RPL (remainderl, long double, (long double x, long double y));
1976 # else
1977 # if !@HAVE_DECL_REMAINDERL@
1978 # undef remainderl
1979 # if !(defined __cplusplus && defined _AIX)
1980 _GL_FUNCDECL_SYS (remainderl, long double, (long double x, long double y));
1981 # endif
1982 # endif
1983 _GL_CXXALIAS_SYS (remainderl, long double, (long double x, long double y));
1984 # endif
1985 # if __GLIBC__ >= 2
1986 _GL_CXXALIASWARN (remainderl);
1987 # endif
1988 #elif defined GNULIB_POSIXCHECK
1989 # undef remainderl
1990 # if HAVE_RAW_DECL_REMAINDERL
1991 _GL_WARN_ON_USE (remainderl, "remainderl is unportable - "
1992 "use gnulib module remainderl for portability");
1993 # endif
1994 #endif
1997 #if @GNULIB_RINTF@
1998 # if !@HAVE_DECL_RINTF@
1999 _GL_FUNCDECL_SYS (rintf, float, (float x));
2000 # endif
2001 _GL_CXXALIAS_SYS (rintf, float, (float x));
2002 _GL_CXXALIASWARN (rintf);
2003 #elif defined GNULIB_POSIXCHECK
2004 # undef rintf
2005 # if HAVE_RAW_DECL_RINTF
2006 _GL_WARN_ON_USE (rintf, "rintf is unportable - "
2007 "use gnulib module rintf for portability");
2008 # endif
2009 #endif
2011 #if @GNULIB_RINT@
2012 # if !@HAVE_RINT@
2013 _GL_FUNCDECL_SYS (rint, double, (double x));
2014 # endif
2015 _GL_CXXALIAS_SYS (rint, double, (double x));
2016 # if __GLIBC__ >= 2
2017 _GL_CXXALIASWARN1 (rint, double, (double x));
2018 # endif
2019 #elif defined GNULIB_POSIXCHECK
2020 # undef rint
2021 # if HAVE_RAW_DECL_RINT
2022 _GL_WARN_ON_USE (rint, "rint is unportable - "
2023 "use gnulib module rint for portability");
2024 # endif
2025 #endif
2027 #if @GNULIB_RINTL@
2028 # if @REPLACE_RINTL@
2029 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2030 # undef rintl
2031 # define rintl rpl_rintl
2032 # endif
2033 _GL_FUNCDECL_RPL (rintl, long double, (long double x));
2034 _GL_CXXALIAS_RPL (rintl, long double, (long double x));
2035 # else
2036 # if !@HAVE_RINTL@
2037 _GL_FUNCDECL_SYS (rintl, long double, (long double x));
2038 # endif
2039 _GL_CXXALIAS_SYS (rintl, long double, (long double x));
2040 # endif
2041 # if __GLIBC__ >= 2
2042 _GL_CXXALIASWARN (rintl);
2043 # endif
2044 #elif defined GNULIB_POSIXCHECK
2045 # undef rintl
2046 # if HAVE_RAW_DECL_RINTL
2047 _GL_WARN_ON_USE (rintl, "rintl is unportable - "
2048 "use gnulib module rintl for portability");
2049 # endif
2050 #endif
2053 #if @GNULIB_ROUNDF@
2054 # if @REPLACE_ROUNDF@
2055 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2056 # undef roundf
2057 # define roundf rpl_roundf
2058 # endif
2059 _GL_FUNCDECL_RPL (roundf, float, (float x));
2060 _GL_CXXALIAS_RPL (roundf, float, (float x));
2061 # else
2062 # if !@HAVE_DECL_ROUNDF@
2063 _GL_FUNCDECL_SYS (roundf, float, (float x));
2064 # endif
2065 _GL_CXXALIAS_SYS (roundf, float, (float x));
2066 # endif
2067 _GL_CXXALIASWARN (roundf);
2068 #elif defined GNULIB_POSIXCHECK
2069 # undef roundf
2070 # if HAVE_RAW_DECL_ROUNDF
2071 _GL_WARN_ON_USE (roundf, "roundf is unportable - "
2072 "use gnulib module roundf for portability");
2073 # endif
2074 #endif
2076 #if @GNULIB_ROUND@
2077 # if @REPLACE_ROUND@
2078 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2079 # undef round
2080 # define round rpl_round
2081 # endif
2082 _GL_FUNCDECL_RPL (round, double, (double x));
2083 _GL_CXXALIAS_RPL (round, double, (double x));
2084 # else
2085 # if !@HAVE_DECL_ROUND@
2086 _GL_FUNCDECL_SYS (round, double, (double x));
2087 # endif
2088 _GL_CXXALIAS_SYS (round, double, (double x));
2089 # endif
2090 # if __GLIBC__ >= 2
2091 _GL_CXXALIASWARN1 (round, double, (double x));
2092 # endif
2093 #elif defined GNULIB_POSIXCHECK
2094 # undef round
2095 # if HAVE_RAW_DECL_ROUND
2096 _GL_WARN_ON_USE (round, "round is unportable - "
2097 "use gnulib module round for portability");
2098 # endif
2099 #endif
2101 #if @GNULIB_ROUNDL@
2102 # if @REPLACE_ROUNDL@
2103 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2104 # undef roundl
2105 # define roundl rpl_roundl
2106 # endif
2107 _GL_FUNCDECL_RPL (roundl, long double, (long double x));
2108 _GL_CXXALIAS_RPL (roundl, long double, (long double x));
2109 # else
2110 # if !@HAVE_DECL_ROUNDL@
2111 # undef roundl
2112 # if !(defined __cplusplus && defined _AIX)
2113 _GL_FUNCDECL_SYS (roundl, long double, (long double x));
2114 # endif
2115 # endif
2116 _GL_CXXALIAS_SYS (roundl, long double, (long double x));
2117 # endif
2118 # if __GLIBC__ >= 2
2119 _GL_CXXALIASWARN (roundl);
2120 # endif
2121 #elif defined GNULIB_POSIXCHECK
2122 # undef roundl
2123 # if HAVE_RAW_DECL_ROUNDL
2124 _GL_WARN_ON_USE (roundl, "roundl is unportable - "
2125 "use gnulib module roundl for portability");
2126 # endif
2127 #endif
2130 #if @GNULIB_SINF@
2131 # if @REPLACE_SINF@
2132 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2133 # undef sinf
2134 # define sinf rpl_sinf
2135 # endif
2136 _GL_FUNCDECL_RPL (sinf, float, (float x));
2137 _GL_CXXALIAS_RPL (sinf, float, (float x));
2138 # else
2139 # if !@HAVE_SINF@
2140 # undef sinf
2141 _GL_FUNCDECL_SYS (sinf, float, (float x));
2142 # endif
2143 _GL_CXXALIAS_SYS (sinf, float, (float x));
2144 # endif
2145 _GL_CXXALIASWARN (sinf);
2146 #elif defined GNULIB_POSIXCHECK
2147 # undef sinf
2148 # if HAVE_RAW_DECL_SINF
2149 _GL_WARN_ON_USE (sinf, "sinf is unportable - "
2150 "use gnulib module sinf for portability");
2151 # endif
2152 #endif
2154 #if @GNULIB_SINL@
2155 # if !@HAVE_SINL@ || !@HAVE_DECL_SINL@
2156 # undef sinl
2157 _GL_FUNCDECL_SYS (sinl, long double, (long double x));
2158 # endif
2159 _GL_CXXALIAS_SYS (sinl, long double, (long double x));
2160 # if __GLIBC__ >= 2
2161 _GL_CXXALIASWARN (sinl);
2162 # endif
2163 #elif defined GNULIB_POSIXCHECK
2164 # undef sinl
2165 # if HAVE_RAW_DECL_SINL
2166 _GL_WARN_ON_USE (sinl, "sinl is unportable - "
2167 "use gnulib module sinl for portability");
2168 # endif
2169 #endif
2172 #if @GNULIB_SINHF@
2173 # if @REPLACE_SINHF@
2174 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2175 # undef sinhf
2176 # define sinhf rpl_sinhf
2177 # endif
2178 _GL_FUNCDECL_RPL (sinhf, float, (float x));
2179 _GL_CXXALIAS_RPL (sinhf, float, (float x));
2180 # else
2181 # if !@HAVE_SINHF@
2182 # undef sinhf
2183 _GL_FUNCDECL_SYS (sinhf, float, (float x));
2184 # endif
2185 _GL_CXXALIAS_SYS (sinhf, float, (float x));
2186 # endif
2187 _GL_CXXALIASWARN (sinhf);
2188 #elif defined GNULIB_POSIXCHECK
2189 # undef sinhf
2190 # if HAVE_RAW_DECL_SINHF
2191 _GL_WARN_ON_USE (sinhf, "sinhf is unportable - "
2192 "use gnulib module sinhf for portability");
2193 # endif
2194 #endif
2197 #if @GNULIB_SQRTF@
2198 # if @REPLACE_SQRTF@
2199 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2200 # undef sqrtf
2201 # define sqrtf rpl_sqrtf
2202 # endif
2203 _GL_FUNCDECL_RPL (sqrtf, float, (float x));
2204 _GL_CXXALIAS_RPL (sqrtf, float, (float x));
2205 # else
2206 # if !@HAVE_SQRTF@
2207 # undef sqrtf
2208 _GL_FUNCDECL_SYS (sqrtf, float, (float x));
2209 # endif
2210 _GL_CXXALIAS_SYS (sqrtf, float, (float x));
2211 # endif
2212 _GL_CXXALIASWARN (sqrtf);
2213 #elif defined GNULIB_POSIXCHECK
2214 # undef sqrtf
2215 # if HAVE_RAW_DECL_SQRTF
2216 _GL_WARN_ON_USE (sqrtf, "sqrtf is unportable - "
2217 "use gnulib module sqrtf for portability");
2218 # endif
2219 #endif
2221 #if @GNULIB_SQRTL@
2222 # if @REPLACE_SQRTL@
2223 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2224 # undef sqrtl
2225 # define sqrtl rpl_sqrtl
2226 # endif
2227 _GL_FUNCDECL_RPL (sqrtl, long double, (long double x));
2228 _GL_CXXALIAS_RPL (sqrtl, long double, (long double x));
2229 # else
2230 # if !@HAVE_SQRTL@ || !@HAVE_DECL_SQRTL@
2231 # undef sqrtl
2232 _GL_FUNCDECL_SYS (sqrtl, long double, (long double x));
2233 # endif
2234 _GL_CXXALIAS_SYS (sqrtl, long double, (long double x));
2235 # endif
2236 # if __GLIBC__ >= 2
2237 _GL_CXXALIASWARN (sqrtl);
2238 # endif
2239 #elif defined GNULIB_POSIXCHECK
2240 # undef sqrtl
2241 # if HAVE_RAW_DECL_SQRTL
2242 _GL_WARN_ON_USE (sqrtl, "sqrtl is unportable - "
2243 "use gnulib module sqrtl for portability");
2244 # endif
2245 #endif
2248 #if @GNULIB_TANF@
2249 # if @REPLACE_TANF@
2250 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2251 # undef tanf
2252 # define tanf rpl_tanf
2253 # endif
2254 _GL_FUNCDECL_RPL (tanf, float, (float x));
2255 _GL_CXXALIAS_RPL (tanf, float, (float x));
2256 # else
2257 # if !@HAVE_TANF@
2258 # undef tanf
2259 _GL_FUNCDECL_SYS (tanf, float, (float x));
2260 # endif
2261 _GL_CXXALIAS_SYS (tanf, float, (float x));
2262 # endif
2263 _GL_CXXALIASWARN (tanf);
2264 #elif defined GNULIB_POSIXCHECK
2265 # undef tanf
2266 # if HAVE_RAW_DECL_TANF
2267 _GL_WARN_ON_USE (tanf, "tanf is unportable - "
2268 "use gnulib module tanf for portability");
2269 # endif
2270 #endif
2272 #if @GNULIB_TANL@
2273 # if !@HAVE_TANL@ || !@HAVE_DECL_TANL@
2274 # undef tanl
2275 _GL_FUNCDECL_SYS (tanl, long double, (long double x));
2276 # endif
2277 _GL_CXXALIAS_SYS (tanl, long double, (long double x));
2278 # if __GLIBC__ >= 2
2279 _GL_CXXALIASWARN (tanl);
2280 # endif
2281 #elif defined GNULIB_POSIXCHECK
2282 # undef tanl
2283 # if HAVE_RAW_DECL_TANL
2284 _GL_WARN_ON_USE (tanl, "tanl is unportable - "
2285 "use gnulib module tanl for portability");
2286 # endif
2287 #endif
2290 #if @GNULIB_TANHF@
2291 # if @REPLACE_TANHF@
2292 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2293 # undef tanhf
2294 # define tanhf rpl_tanhf
2295 # endif
2296 _GL_FUNCDECL_RPL (tanhf, float, (float x));
2297 _GL_CXXALIAS_RPL (tanhf, float, (float x));
2298 # else
2299 # if !@HAVE_TANHF@
2300 # undef tanhf
2301 _GL_FUNCDECL_SYS (tanhf, float, (float x));
2302 # endif
2303 _GL_CXXALIAS_SYS (tanhf, float, (float x));
2304 # endif
2305 _GL_CXXALIASWARN (tanhf);
2306 #elif defined GNULIB_POSIXCHECK
2307 # undef tanhf
2308 # if HAVE_RAW_DECL_TANHF
2309 _GL_WARN_ON_USE (tanhf, "tanhf is unportable - "
2310 "use gnulib module tanhf for portability");
2311 # endif
2312 #endif
2315 #if @GNULIB_TRUNCF@
2316 # if @REPLACE_TRUNCF@
2317 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2318 # undef truncf
2319 # define truncf rpl_truncf
2320 # endif
2321 _GL_FUNCDECL_RPL (truncf, float, (float x));
2322 _GL_CXXALIAS_RPL (truncf, float, (float x));
2323 # else
2324 # if !@HAVE_DECL_TRUNCF@
2325 _GL_FUNCDECL_SYS (truncf, float, (float x));
2326 # endif
2327 _GL_CXXALIAS_SYS (truncf, float, (float x));
2328 # endif
2329 _GL_CXXALIASWARN (truncf);
2330 #elif defined GNULIB_POSIXCHECK
2331 # undef truncf
2332 # if HAVE_RAW_DECL_TRUNCF
2333 _GL_WARN_ON_USE (truncf, "truncf is unportable - "
2334 "use gnulib module truncf for portability");
2335 # endif
2336 #endif
2338 #if @GNULIB_TRUNC@
2339 # if @REPLACE_TRUNC@
2340 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2341 # undef trunc
2342 # define trunc rpl_trunc
2343 # endif
2344 _GL_FUNCDECL_RPL (trunc, double, (double x));
2345 _GL_CXXALIAS_RPL (trunc, double, (double x));
2346 # else
2347 # if !@HAVE_DECL_TRUNC@
2348 _GL_FUNCDECL_SYS (trunc, double, (double x));
2349 # endif
2350 _GL_CXXALIAS_SYS (trunc, double, (double x));
2351 # endif
2352 # if __GLIBC__ >= 2
2353 _GL_CXXALIASWARN1 (trunc, double, (double x));
2354 # endif
2355 #elif defined GNULIB_POSIXCHECK
2356 # undef trunc
2357 # if HAVE_RAW_DECL_TRUNC
2358 _GL_WARN_ON_USE (trunc, "trunc is unportable - "
2359 "use gnulib module trunc for portability");
2360 # endif
2361 #endif
2363 #if @GNULIB_TRUNCL@
2364 # if @REPLACE_TRUNCL@
2365 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2366 # undef truncl
2367 # define truncl rpl_truncl
2368 # endif
2369 _GL_FUNCDECL_RPL (truncl, long double, (long double x));
2370 _GL_CXXALIAS_RPL (truncl, long double, (long double x));
2371 # else
2372 # if !@HAVE_DECL_TRUNCL@
2373 _GL_FUNCDECL_SYS (truncl, long double, (long double x));
2374 # endif
2375 _GL_CXXALIAS_SYS (truncl, long double, (long double x));
2376 # endif
2377 # if __GLIBC__ >= 2
2378 _GL_CXXALIASWARN (truncl);
2379 # endif
2380 #elif defined GNULIB_POSIXCHECK
2381 # undef truncl
2382 # if HAVE_RAW_DECL_TRUNCL
2383 _GL_WARN_ON_USE (truncl, "truncl is unportable - "
2384 "use gnulib module truncl for portability");
2385 # endif
2386 #endif
2389 #if @GNULIB_MDA_Y0@
2390 /* On native Windows, map 'y0' to '_y0', so that -loldnames is not
2391 required. In C++ with GNULIB_NAMESPACE, avoid differences between
2392 platforms by defining GNULIB_NAMESPACE::y0 always. */
2393 # if defined _WIN32 && !defined __CYGWIN__
2394 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2395 # undef y0
2396 # define y0 _y0
2397 # endif
2398 _GL_CXXALIAS_MDA (y0, double, (double x));
2399 # else
2400 _GL_CXXALIAS_SYS (y0, double, (double x));
2401 # endif
2402 _GL_CXXALIASWARN (y0);
2403 #endif
2405 #if @GNULIB_MDA_Y1@
2406 /* On native Windows, map 'y1' to '_y1', so that -loldnames is not
2407 required. In C++ with GNULIB_NAMESPACE, avoid differences between
2408 platforms by defining GNULIB_NAMESPACE::y1 always. */
2409 # if defined _WIN32 && !defined __CYGWIN__
2410 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2411 # undef y1
2412 # define y1 _y1
2413 # endif
2414 _GL_CXXALIAS_MDA (y1, double, (double x));
2415 # else
2416 _GL_CXXALIAS_SYS (y1, double, (double x));
2417 # endif
2418 _GL_CXXALIASWARN (y1);
2419 #endif
2421 #if @GNULIB_MDA_YN@
2422 /* On native Windows, map 'yn' to '_yn', so that -loldnames is not
2423 required. In C++ with GNULIB_NAMESPACE, avoid differences between
2424 platforms by defining GNULIB_NAMESPACE::yn always. */
2425 # if defined _WIN32 && !defined __CYGWIN__
2426 # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
2427 # undef yn
2428 # define yn _yn
2429 # endif
2430 _GL_CXXALIAS_MDA (yn, double, (int n, double x));
2431 # else
2432 _GL_CXXALIAS_SYS (yn, double, (int n, double x));
2433 # endif
2434 _GL_CXXALIASWARN (yn);
2435 #endif
2438 /* Definitions of function-like macros come here, after the function
2439 declarations. */
2442 #if @GNULIB_ISFINITE@
2443 # if @REPLACE_ISFINITE@
2444 _GL_EXTERN_C int gl_isfinitef (float x);
2445 _GL_EXTERN_C int gl_isfinited (double x);
2446 _GL_EXTERN_C int gl_isfinitel (long double x);
2447 # undef isfinite
2448 # define isfinite(x) \
2449 (sizeof (x) == sizeof (long double) ? gl_isfinitel (x) : \
2450 sizeof (x) == sizeof (double) ? gl_isfinited (x) : \
2451 gl_isfinitef (x))
2452 # endif
2453 # ifdef __cplusplus
2454 # if defined isfinite || defined GNULIB_NAMESPACE
2455 _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isfinite)
2456 # undef isfinite
2457 # if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__ || defined __OpenBSD__ || defined _AIX || (defined _WIN32 && !defined __CYGWIN__)))
2458 /* This platform's <cmath> possibly defines isfinite through a set of inline
2459 functions. */
2460 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isfinite, rpl_isfinite, bool)
2461 # define isfinite rpl_isfinite
2462 # define GNULIB_NAMESPACE_LACKS_ISFINITE 1
2463 # else
2464 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isfinite, isfinite, bool)
2465 # endif
2466 # endif
2467 # endif
2468 #elif defined GNULIB_POSIXCHECK
2469 # if defined isfinite
2470 _GL_WARN_REAL_FLOATING_DECL (isfinite);
2471 # undef isfinite
2472 # define isfinite(x) _GL_WARN_REAL_FLOATING_IMPL (isfinite, x)
2473 # endif
2474 #endif
2477 #if @GNULIB_ISINF@
2478 # if @REPLACE_ISINF@
2479 _GL_EXTERN_C int gl_isinff (float x);
2480 _GL_EXTERN_C int gl_isinfd (double x);
2481 _GL_EXTERN_C int gl_isinfl (long double x);
2482 # undef isinf
2483 # define isinf(x) \
2484 (sizeof (x) == sizeof (long double) ? gl_isinfl (x) : \
2485 sizeof (x) == sizeof (double) ? gl_isinfd (x) : \
2486 gl_isinff (x))
2487 # endif
2488 # ifdef __cplusplus
2489 # if defined isinf || defined GNULIB_NAMESPACE
2490 _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isinf)
2491 # undef isinf
2492 # if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__ || defined __OpenBSD__ || (defined _WIN32 && !defined __CYGWIN__)))
2493 /* This platform's <cmath> possibly defines isinf through a set of inline
2494 functions. */
2495 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isinf, rpl_isinf, bool)
2496 # define isinf rpl_isinf
2497 # define GNULIB_NAMESPACE_LACKS_ISINF 1
2498 # else
2499 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isinf, isinf, bool)
2500 # endif
2501 # endif
2502 # endif
2503 #elif defined GNULIB_POSIXCHECK
2504 # if defined isinf
2505 _GL_WARN_REAL_FLOATING_DECL (isinf);
2506 # undef isinf
2507 # define isinf(x) _GL_WARN_REAL_FLOATING_IMPL (isinf, x)
2508 # endif
2509 #endif
2512 #if @GNULIB_ISNANF@
2513 /* Test for NaN for 'float' numbers. */
2514 # if @HAVE_ISNANF@
2515 /* The original <math.h> included above provides a declaration of isnan macro
2516 or (older) isnanf function. */
2517 # if (__GNUC__ >= 4) || (__clang_major__ >= 4)
2518 /* GCC >= 4.0 and clang provide a type-generic built-in for isnan.
2519 GCC >= 4.0 also provides __builtin_isnanf, but clang doesn't. */
2520 # undef isnanf
2521 # define isnanf(x) __builtin_isnan ((float)(x))
2522 # elif defined isnan
2523 # undef isnanf
2524 # define isnanf(x) isnan ((float)(x))
2525 # endif
2526 # else
2527 /* Test whether X is a NaN. */
2528 # undef isnanf
2529 # define isnanf rpl_isnanf
2530 _GL_EXTERN_C int isnanf (float x);
2531 # endif
2532 #endif
2534 #if @GNULIB_ISNAND@
2535 /* Test for NaN for 'double' numbers.
2536 This function is a gnulib extension, unlike isnan() which applied only
2537 to 'double' numbers earlier but now is a type-generic macro. */
2538 # if @HAVE_ISNAND@
2539 /* The original <math.h> included above provides a declaration of isnan
2540 macro. */
2541 # if (__GNUC__ >= 4) || (__clang_major__ >= 4)
2542 /* GCC >= 4.0 and clang provide a type-generic built-in for isnan. */
2543 # undef isnand
2544 # define isnand(x) __builtin_isnan ((double)(x))
2545 # else
2546 # undef isnand
2547 # define isnand(x) isnan ((double)(x))
2548 # endif
2549 # else
2550 /* Test whether X is a NaN. */
2551 # undef isnand
2552 # define isnand rpl_isnand
2553 _GL_EXTERN_C int isnand (double x);
2554 # endif
2555 #endif
2557 #if @GNULIB_ISNANL@
2558 /* Test for NaN for 'long double' numbers. */
2559 # if @HAVE_ISNANL@
2560 /* The original <math.h> included above provides a declaration of isnan
2561 macro or (older) isnanl function. */
2562 # if (__GNUC__ >= 4) || (__clang_major__ >= 4)
2563 /* GCC >= 4.0 and clang provide a type-generic built-in for isnan.
2564 GCC >= 4.0 also provides __builtin_isnanl, but clang doesn't. */
2565 # undef isnanl
2566 # define isnanl(x) __builtin_isnan ((long double)(x))
2567 # elif defined isnan
2568 # undef isnanl
2569 # define isnanl(x) isnan ((long double)(x))
2570 # endif
2571 # else
2572 /* Test whether X is a NaN. */
2573 # undef isnanl
2574 # define isnanl rpl_isnanl
2575 _GL_EXTERN_C int isnanl (long double x) _GL_ATTRIBUTE_CONST;
2576 # endif
2577 #endif
2579 /* This must come *after* the snippets for GNULIB_ISNANF and GNULIB_ISNANL! */
2580 #if @GNULIB_ISNAN@
2581 # if @REPLACE_ISNAN@
2582 /* We can't just use the isnanf macro (e.g.) as exposed by
2583 isnanf.h (e.g.) here, because those may end up being macros
2584 that recursively expand back to isnan. So use the gnulib
2585 replacements for them directly. */
2586 # if @HAVE_ISNANF@ && (__GNUC__ >= 4) || (__clang_major__ >= 4)
2587 # define gl_isnan_f(x) __builtin_isnan ((float)(x))
2588 # else
2589 _GL_EXTERN_C int rpl_isnanf (float x);
2590 # define gl_isnan_f(x) rpl_isnanf (x)
2591 # endif
2592 # if @HAVE_ISNAND@ && (__GNUC__ >= 4) || (__clang_major__ >= 4)
2593 # define gl_isnan_d(x) __builtin_isnan ((double)(x))
2594 # else
2595 _GL_EXTERN_C int rpl_isnand (double x);
2596 # define gl_isnan_d(x) rpl_isnand (x)
2597 # endif
2598 # if @HAVE_ISNANL@ && (__GNUC__ >= 4) || (__clang_major__ >= 4)
2599 # define gl_isnan_l(x) __builtin_isnan ((long double)(x))
2600 # else
2601 _GL_EXTERN_C int rpl_isnanl (long double x) _GL_ATTRIBUTE_CONST;
2602 # define gl_isnan_l(x) rpl_isnanl (x)
2603 # endif
2604 # undef isnan
2605 # define isnan(x) \
2606 (sizeof (x) == sizeof (long double) ? gl_isnan_l (x) : \
2607 sizeof (x) == sizeof (double) ? gl_isnan_d (x) : \
2608 gl_isnan_f (x))
2609 # elif (__GNUC__ >= 4) || (__clang_major__ >= 4)
2610 # undef isnan
2611 # define isnan(x) \
2612 (sizeof (x) == sizeof (long double) ? __builtin_isnan ((long double)(x)) : \
2613 sizeof (x) == sizeof (double) ? __builtin_isnan ((double)(x)) : \
2614 __builtin_isnan ((float)(x)))
2615 # endif
2616 # ifdef __cplusplus
2617 # if defined isnan || defined GNULIB_NAMESPACE
2618 _GL_MATH_CXX_REAL_FLOATING_DECL_1 (isnan)
2619 # undef isnan
2620 # if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__ && __clang_major__ < 12) || (defined __FreeBSD__ && (__clang_major__ < 7 || __clang_major__ >= 11)) || defined __OpenBSD__ || (defined _WIN32 && !defined __CYGWIN__)))
2621 /* This platform's <cmath> possibly defines isnan through a set of inline
2622 functions. */
2623 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isnan, rpl_isnan, bool)
2624 # define isnan rpl_isnan
2625 # define GNULIB_NAMESPACE_LACKS_ISNAN 1
2626 # else
2627 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (isnan, isnan, bool)
2628 # endif
2629 # endif
2630 # else
2631 /* Ensure isnan is a macro. */
2632 # ifndef isnan
2633 # define isnan isnan
2634 # endif
2635 # endif
2636 #elif defined GNULIB_POSIXCHECK
2637 # if defined isnan
2638 _GL_WARN_REAL_FLOATING_DECL (isnan);
2639 # undef isnan
2640 # define isnan(x) _GL_WARN_REAL_FLOATING_IMPL (isnan, x)
2641 # endif
2642 #endif
2645 #if @GNULIB_SIGNBIT@
2646 # if (@REPLACE_SIGNBIT_USING_BUILTINS@ \
2647 && (!defined __cplusplus || __cplusplus < 201103))
2648 # undef signbit
2649 /* GCC >= 4.0 and clang provide three built-ins for signbit. */
2650 # define signbit(x) \
2651 (sizeof (x) == sizeof (long double) ? __builtin_signbitl (x) : \
2652 sizeof (x) == sizeof (double) ? __builtin_signbit (x) : \
2653 __builtin_signbitf (x))
2654 # endif
2655 # if @REPLACE_SIGNBIT@ && !GNULIB_defined_signbit
2656 # undef signbit
2657 _GL_EXTERN_C int gl_signbitf (float arg);
2658 _GL_EXTERN_C int gl_signbitd (double arg);
2659 _GL_EXTERN_C int gl_signbitl (long double arg);
2660 # if (__GNUC__ >= 2 || defined __clang__) && !defined __STRICT_ANSI__
2661 # define _GL_NUM_UINT_WORDS(type) \
2662 ((sizeof (type) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
2663 # if defined FLT_SIGNBIT_WORD && defined FLT_SIGNBIT_BIT && !defined gl_signbitf
2664 # define gl_signbitf_OPTIMIZED_MACRO
2665 # define gl_signbitf(arg) \
2666 ({ union { float _value; \
2667 unsigned int _word[_GL_NUM_UINT_WORDS (float)]; \
2668 } _m; \
2669 _m._value = (arg); \
2670 (_m._word[FLT_SIGNBIT_WORD] >> FLT_SIGNBIT_BIT) & 1; \
2672 # endif
2673 # if defined DBL_SIGNBIT_WORD && defined DBL_SIGNBIT_BIT && !defined gl_signbitd
2674 # define gl_signbitd_OPTIMIZED_MACRO
2675 # define gl_signbitd(arg) \
2676 ({ union { double _value; \
2677 unsigned int _word[_GL_NUM_UINT_WORDS (double)]; \
2678 } _m; \
2679 _m._value = (arg); \
2680 (_m._word[DBL_SIGNBIT_WORD] >> DBL_SIGNBIT_BIT) & 1; \
2682 # endif
2683 # if defined LDBL_SIGNBIT_WORD && defined LDBL_SIGNBIT_BIT && !defined gl_signbitl
2684 # define gl_signbitl_OPTIMIZED_MACRO
2685 # define gl_signbitl(arg) \
2686 ({ union { long double _value; \
2687 unsigned int _word[_GL_NUM_UINT_WORDS (long double)]; \
2688 } _m; \
2689 _m._value = (arg); \
2690 (_m._word[LDBL_SIGNBIT_WORD] >> LDBL_SIGNBIT_BIT) & 1; \
2692 # endif
2693 # endif
2694 # define signbit(x) \
2695 (sizeof (x) == sizeof (long double) ? gl_signbitl (x) : \
2696 sizeof (x) == sizeof (double) ? gl_signbitd (x) : \
2697 gl_signbitf (x))
2698 # define GNULIB_defined_signbit 1
2699 # endif
2700 # ifdef __cplusplus
2701 # if defined signbit || defined GNULIB_NAMESPACE
2702 _GL_MATH_CXX_REAL_FLOATING_DECL_1 (signbit)
2703 # undef signbit
2704 # if __GNUC__ >= 6 || (defined __clang__ && !((defined __APPLE__ && defined __MACH__) || defined __FreeBSD__ || defined __OpenBSD__ || defined _AIX || (defined _WIN32 && !defined __CYGWIN__)))
2705 /* This platform's <cmath> possibly defines signbit through a set of inline
2706 functions. */
2707 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (signbit, rpl_signbit, bool)
2708 # define signbit rpl_signbit
2709 # define GNULIB_NAMESPACE_LACKS_SIGNBIT 1
2710 # else
2711 _GL_MATH_CXX_REAL_FLOATING_DECL_2 (signbit, signbit, bool)
2712 # endif
2713 # endif
2714 # endif
2715 #elif defined GNULIB_POSIXCHECK
2716 # if defined signbit
2717 _GL_WARN_REAL_FLOATING_DECL (signbit);
2718 # undef signbit
2719 # define signbit(x) _GL_WARN_REAL_FLOATING_IMPL (signbit, x)
2720 # endif
2721 #endif
2723 _GL_INLINE_HEADER_END
2725 #endif /* _@GUARD_PREFIX@_MATH_H */
2726 #endif /* _GL_INCLUDING_MATH_H */
2727 #endif /* _@GUARD_PREFIX@_MATH_H */