4.7.3 Exceptions Related to Arithmetic

All predicates that evaluate arithmetic expressions will raise the following exceptions:

instantiation_error
type_error
Atom given as expression, or float given where integer required.
evaluation_error
Attempting to divide by zero, or undefined function, or function undefined for the given argument.
representation_error
Integer value too large to be represented.

The reference page for such predicates will simply refer to these as “Arithmetic errors” and will go on to detail other exceptions that may be raised for a particular predicate.


Send feedback on this subject.