summaryrefslogtreecommitdiff
path: root/src/complex/cprojf.c
blob: 71129743cf839b3211e8e7852173bc5f676ef493 (plain) (blame)
1
2
3
4
5
6
7
8
#include "libm.h"

float complex cprojf(float complex z)
{
	if (isinf(crealf(z)) || isinf(cimagf(z)))
		return cpackf(INFINITY, copysignf(0.0, crealf(z)));
	return z;
}