summaryrefslogtreecommitdiffstats
path: root/libm/w_cabs.c
blob: 485e120db7b4b96d0f2274cc53166c45e0c49fc2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/*
 * cabs() wrapper for hypot().
 *
 * Written by J.T. Conklin, <jtc@wimsey.com>
 * Placed into the Public Domain, 1994.
 */

#include <complex.h>
#include <math.h>

libm_hidden_proto(hypot)

double cabs(double _Complex z)
{
	return hypot(__real__ z, __imag__ z);
}