This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
[PATCH 4/4] Macroize inclusion of math-finite.h (part 4)
- From: "Gabriel F. T. Gomes" <gftg at linux dot vnet dot ibm dot com>
- To: libc-alpha at sourceware dot org
- Date: Mon, 13 Mar 2017 18:01:59 -0300
- Subject: [PATCH 4/4] Macroize inclusion of math-finite.h (part 4)
- Authentication-results: sourceware.org; auth=none
- References: <1489438919-4009-1-git-send-email-gftg@linux.vnet.ibm.com>
---
math/bits/math-finite.h | 29 ++++++-----------------------
1 file changed, 6 insertions(+), 23 deletions(-)
diff --git a/math/bits/math-finite.h b/math/bits/math-finite.h
index 1b5a243..c01c5c2 100644
--- a/math/bits/math-finite.h
+++ b/math/bits/math-finite.h
@@ -203,33 +203,16 @@ __MATH_REDIRCALL (sqrt, , (_Mdouble_));
#if defined __USE_ISOC99 && defined __extern_always_inline
/* tgamma. */
-extern double __gamma_r_finite (double, int *);
-__extern_always_inline double __NTH (tgamma (double __d))
-{
- int __local_signgam = 0;
- double __res = __gamma_r_finite (__d, &__local_signgam);
- return __local_signgam < 0 ? -__res : __res;
-}
-extern float __gammaf_r_finite (float, int *);
-__extern_always_inline float __NTH (tgammaf (float __d))
-{
- int __local_signgam = 0;
- float __res = __gammaf_r_finite (__d, &__local_signgam);
- return __local_signgam < 0 ? -__res : __res;
-}
-# ifdef __MATH_DECLARE_LDOUBLE
-extern long double __gammal_r_finite (long double, int *);
-__extern_always_inline long double __NTH (tgammal (long double __d))
+extern _Mdouble_
+__REDIRFROM (__gamma, _r_finite, _MSUF_) (_Mdouble_, int *);
+
+__extern_always_inline _Mdouble_
+__NTH (__REDIRFROM (tgamma, , _MSUF_) (_Mdouble_ __d))
{
int __local_signgam = 0;
-# ifdef __NO_LONG_DOUBLE_MATH
- long double __res = __gamma_r_finite (__d, &__local_signgam);
-# else
- long double __res = __gammal_r_finite (__d, &__local_signgam);
-# endif
+ _Mdouble_ __res = __REDIRTO (gamma, _r, _MSUF_) (__d, &__local_signgam);
return __local_signgam < 0 ? -__res : __res;
}
-# endif
#endif
#undef __REDIRFROM
--
2.4.11