The following tests give access to basic information about the current invocation.
The invocation number of the current goal is Inv. Invocation numbers start from 1.
The current execution depth is Depth.
The current goal is an instance of the module name expanded MGoal template. The
current goal and MGoal are unified. This condition is equivalent
subsumes/2 is defined
library(terms), see lib-terms).
The module name expanded MFunc template matches (see notes below)
the functor (M
/N) of the current goal.
The unification required for matching is carried out.
The current goal is invoked from module Module. For compiled
calls to built-in predicates Module will always be
The private information associated with the current goal is GoalPriv. This is initialized to an unbound variable at the Call port. It is strongly recommended that GoalPriv be used as an open ended list, see Storing User Information in the Backtrace.
true if the current invocation has exited,
false otherwise. This condition is mainly used for looking at
past execution states.
The invocation number of the debugger-parent (see notes below) of the current goal is Inv.
The youngest debugger-ancestor of the current goal, which is an instance of the module name expanded AncGoal template, is at invocation number Inv. The unification required for matching is carried out.
The debugger-parent of a goal is the youngest ancestor of the goal present on the backtrace. This will differ from the ordinary parent if not all goals are traced, e.g. if the goal in question is reached in zip mode. A debugger-ancestor of a goal is any of its ancestors on the backtrace.
ancestor tests above, there is a given
module qualified goal template, say ModT
and it is matched against a concrete goal term
:Goal in the execution state. This matching is carried
out as follows:
:Goal and ModT
:Goal is an exported variant of the other, or both are imported from the same module.
Similar matching rules apply for predicate functors, in the
pred condition. In this test the argument holds a
module qualified functor template, say
/Arity, and this is matched against a
concrete goal term Mod
:Goal in the execution
/Arity, and this unification is carried out.