The Prolog interpreter activates the goals of the debug clause
fork in case some debug mode is set. The Prolog flag sys_cloak
allows temporarily disabling any debug mode for a Prolog
interpreter. The predicate sys_ignore/1 will run a goal with this
The debug clause fork is pickled with the instrumentation
built-ins sys_in/0, sys_out/0 and sys_at/0. The end-user is not
supposed to use them. They need to have public access so that they
can be called from any clause fork.
The following modehandling predicates are provided:
- This instrumentation hook should succeed. It is called before
a goal is called every time a goal is called.
- This instrumentation hook should succeed. It is called after a
goal exits every time a goal exits.
- This instrumentation hook should succeeds. It is called after
a head unification succeeds and before the attribute variable
unify hooks are called.
The following Prolog flags for mode handling are provided:
- Legal values are on and off. The flag indicates whether the
interpreter currently should ignore the debug mode. Default
value is off. The value can be changed.
- Legal values are on and off. The flag is per knowledge base
and is inherited when predicates are created. Default value is
on. The value can be changed.
The following mode handling predicate properties are provided:
- The property indicates that the clauses of the predicate
should not be instrumented for debugging. The value can be