xref: /freebsd/lib/msun/src/w_cabsf.c (revision ef5d438ed4bc17ad7ece3e40fe4d1f9baf3aadf7)
1 /*
2  * cabsf() wrapper for hypotf().
3  *
4  * Written by J.T. Conklin, <jtc@wimsey.com>
5  * Placed into the Public Domain, 1994.
6  */
7 
8 #include "math.h"
9 #include "math_private.h"
10 
11 struct complex {
12 	float x;
13 	float y;
14 };
15 
16 float
17 cabsf(z)
18 	struct complex z;
19 {
20 	return hypotf(z.x, z.y);
21 }
22