Previous Up Next

15.3  Debugging-related Predicate Properties

Predicates have a number of properties which can be listed using the pred/1 built-in. The following predicate flags and properties affect the way the predicate is traced by the debugger:

debugged

Indicates whether the predicate has been compiled in debug-compile mode. If on, calls to the predicate’s subgoal will be traced. The value of this property can only be changed by re-compiling the predicate in a different mode.
leash

If notrace, no port of the predicate will be shown in the trace (but the invocations will be counted nevertheless). If stop, the ports of this predicate will be shown and the debugger will stop and await new commands. (The print setting is currently not supported). The value of this property can be changed with traceable/1, untraceable/1 or set_flag/3.
spy

If on, the predicate has a spy-point and the debugger will stop at its ports when in leap mode. The value of this property can be changed with spy/1, nospy/1 or set_flag/3.
skipped

If on, the predicate’s subgoal will not be traced even if it has been compiled in debug-compile mode. The value of this property can be changed with skipped/1, unskipped/1 or set_flag/3.
start_tracing

If on, a call to the predicate will activate the debugger if it is not already running. Only the execution within this predicate’s box will be traced. This is useful for debugging part of a big program without having to change the source code. The effect is similar to wrapping all call of the predicate into trace/1.

Previous Up Next