aboutsummaryrefslogtreecommitdiff
path: root/std/math/inf.zig
blob: e1bfbb197ac9f8461fb233d0fdac761c2fe6602d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
const std = @import("../std.zig");
const math = std.math;

pub fn inf(comptime T: type) T {
    return switch (T) {
        f16 => math.inf_f16,
        f32 => math.inf_f32,
        f64 => math.inf_f64,
        f128 => math.inf_f128,
        else => @compileError("inf not implemented for " ++ @typeName(T)),
    };
}