Skip to content

Modern Math ClearFpExceptions

Paul Squires edited this page Oct 19, 2026 · 5 revisions

Home › Math Library › Math Library › ClearFpExceptions

ClearFpExceptions

Clears every floating-point exception flag.

Syntax

ClearFpExceptions( )

Examples

#import "std/numeric"
using numeric

'' Clears every sticky flag at once. They ACCUMULATE until cleared, so
'' the sequence is always: clear, compute, test.
ClearFpExceptions( )
print TestFpException( FP_DIVBYZERO )     '' false

dim as float64 z = 0.0
dim as float64 r = 1.0 / z
print TestFpException( FP_DIVBYZERO )     '' true

Library: Math Library
Category: Math Library
Documented under: Nothing Becomes A Keyword

Clone this wiki locally