Many, but not all, C functions return one of the codes
SP_SUCCESS for success,
SP_FAILURE for failure,
SP_ERROR if an error condition occurred, or if an uncaught
exception was raised during a call from C to Prolog.
If the value is
SP_ERROR, the macro
SP_errno will return a
value (an integer) describing the error condition.
SP_error_message() returns a pointer to the diagnostic
message corresponding to a specified error number.
See mpg-ref-ove for a description of the conventions observed in the Reference Pages for Prolog predicates. C function Reference Pages differ primarily in the synopsis. Also, the Reference Page for each C function documents its return values.
The following function annotations are used in the Reference Pages:
The function is user defined and is called in some specific context.
The function is defined as a C macro.
It is only meaningful to call the function before initializing the Prolog engine