DoxigAlpha

asin

Returns the arc-sin of x.

Special Cases:

  • asin(+-0) = +-0
  • asin(x) = nan if x < -1 or x > 1

Function parameters

Parameters

#
x:anytype

Returns the arc-sin of x.

Functions

#
asin
Returns the arc-sin of x.

Source

Implementation

#
pub fn asin(x: anytype) @TypeOf(x) {
    const T = @TypeOf(x);
    return switch (T) {
        f32 => asin32(x),
        f64 => asin64(x),
        else => @compileError("asin not implemented for " ++ @typeName(T)),
    };
}