Skip to main content

math.IsInf

Check if value is infinite (sign: 1=+inf, -1=-inf, 0=either)

math.IsInf(x: float64, sign: int) -> bool

Arguments

NameType
xfloat64
signint

Example

{{ math.IsInf(1/0, 1) }}

Returns true.