We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent afc7ddc commit b9a133eCopy full SHA for b9a133e
1 file changed
lib/libm/wf_tgamma.c
@@ -35,6 +35,10 @@
35
{
36
float y;
37
int local_signgam;
38
+ if (!isfinite(x)) {
39
+ /* special cases: tgammaf(nan)=nan, tgammaf(inf)=inf, tgammaf(-inf)=nan */
40
+ return x + INFINITY;
41
+ }
42
y = expf(__ieee754_lgammaf_r(x,&local_signgam));
43
if (local_signgam < 0) y = -y;
44
#ifdef _IEEE_LIBM
0 commit comments