math.is_infinite

BOOLmath.is_infiniteFLOATx

Available inall subroutines.

Determines whether a floating point value is an infinity. See floating point classifications for more information.

Example

declare local var.f FLOAT;
set var.f = math.POS_INFINITY;
set var.f -= 1; # +∞ - 1 produces +∞
if (math.is_infinite(var.f)) {
log "infinity";
}

User contributed notes

BETA

Do you see an error in this page? Do you have an interesting use case, example or edge case people should know about? Share your knowledge and help people who are reading this page! (Comments are moderated; for support, please contact Fastly support)