libm: Sync with FreeBSD (~50 math functions added)
[dragonfly.git] / lib / libm / complex / w_cabsl.c
CommitLineData
1a3b704c
JM
1/*
2 * cabs() wrapper for hypot().
3 *
4 * Written by J.T. Conklin, <jtc@wimsey.com>
5 * Placed into the Public Domain, 1994.
6 *
7 * Modified by Steven G. Kargl for the long double type.
8 *
9 * FreeBSD SVN: 177757 (2008-03-30)
10 */
11
12#include <complex.h>
13#include <math.h>
14
15long double
16cabsl(long double complex z)
17{
18 return hypotl(creall(z), cimagl(z));
19}