up previous next
assert    --    check an assertion


Syntax
assert(cond: BOOL)

Description
This function always evaluates its argument. If the argument is not true then an exception is thrown. This function is intended for use only during development, and should not be used in released code.

Example
/**/  define fn(X)
/**/    assert(X > 0);
/**/    return FloorSqrt(X);
/**/  enddefine;

/**/  fn(3);
1
-- /**/  fn(-3); --> ERROR: assertion failed (as expected)

See Also