@@ -23,42 +23,3 @@ _Py_log1p(double x)
23
23
}
24
24
25
25
#define m_log1p _Py_log1p
26
-
27
- /*
28
- wrapper for atan2 that deals directly with special cases before
29
- delegating to the platform libm for the remaining cases. This
30
- is necessary to get consistent behaviour across platforms.
31
- Windows, FreeBSD and alpha Tru64 are amongst platforms that don't
32
- always follow C99. Windows screws up atan2 for inf and nan, and
33
- alpha Tru64 5.1 doesn't follow C99 for atan2(0., 0.).
34
- */
35
-
36
- static double
37
- _Py_atan2 (double y , double x )
38
- {
39
- if (isnan (x ) || isnan (y ))
40
- return Py_NAN ;
41
- if (isinf (y )) {
42
- if (isinf (x )) {
43
- if (copysign (1. , x ) == 1. )
44
- /* atan2(+-inf, +inf) == +-pi/4 */
45
- return copysign (0.25 * Py_MATH_PI , y );
46
- else
47
- /* atan2(+-inf, -inf) == +-pi*3/4 */
48
- return copysign (0.75 * Py_MATH_PI , y );
49
- }
50
- /* atan2(+-inf, x) == +-pi/2 for finite x */
51
- return copysign (0.5 * Py_MATH_PI , y );
52
- }
53
- if (isinf (x ) || y == 0. ) {
54
- if (copysign (1. , x ) == 1. )
55
- /* atan2(+-y, +inf) = atan2(+-0, +x) = +-0. */
56
- return copysign (0. , y );
57
- else
58
- /* atan2(+-y, -inf) = atan2(+-0., -x) = +-pi. */
59
- return copysign (Py_MATH_PI , y );
60
- }
61
- return atan2 (y , x );
62
- }
63
-
64
- #define m_atan2 _Py_atan2
0 commit comments