|
@@ -1385,15 +1385,15 @@ atan2 :: proc{
|
|
|
}
|
|
|
|
|
|
atan :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
|
|
|
- return atan2(x, 1)
|
|
|
+ return atan2(1, x)
|
|
|
}
|
|
|
|
|
|
asin :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
|
|
|
- return atan2(x, sqrt(1 - x*x))
|
|
|
+ return atan2(sqrt(1 - x*x), x)
|
|
|
}
|
|
|
|
|
|
acos :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
|
|
|
- return 2 * atan2(sqrt(1 - x), sqrt(1 + x))
|
|
|
+ return 2 * atan2(sqrt(1 + x), sqrt(1 - x))
|
|
|
}
|
|
|
|
|
|
sinh :: proc "contextless" (x: $T) -> T where intrinsics.type_is_float(T) {
|