|Did you know ...||Search Documentation:|
|Control Flow Commands|
Abort a Abort Prolog execution (see abort/0) Break b Enter a Prolog break environment (see break/0) Creep c Continue execution, stop at next port. (Also
Exit e Terminate Prolog (see halt/0) Fail f Force failure of the current goal Find / Search for a port (see below for the description of this command (section 220.127.116.11)) Ignore i Ignore the current goal, pretending it succeeded Leap l Continue execution, stop at next spy point No debug n Continue execution in’no debug' mode Repeat find . Repeat the last find command (see’Find' (section 18.104.22.168)) Retry r Undo all actions (except for database and I/O actions) back to the
callport of the current goal and resume execution at the
Skip s Continue execution, stop at the next port of this goal (thus skipping all calls to children of this goal) Spy + Set a spy point (see spy/1) on the current predicate. Spy points are described later in the overview (section 2.10.6). No spy - Remove the spy point (see nospy/1) from the current predicate. Spy points are described later in the overview (section 2.10.6). Up u Continue execution, stop at the next port of the parent goal (thus skipping this goal and all calls to children of this goal). This option is useful to stop tracing a failure driven loop.
) Description and Examples
The Find (
/) command continues execution until a port
matching a find pattern is found. After the
/, the user can
enter a line to specify the port to search for. This line consists of a
set of letters indicating the port type, followed by an optional term,
that should unify with the goal run by the port. If no term is specified
it is taken as a variable, searching for any port of the specified type.
If an atom is given, any goal whose functor has a name equal to that
atom matches. Examples:
/f Search for any
/fe solve Search for a
exitport of any goal with name
Search for a call to solve/2 whose first argument is a variable or the atom
Search for any port on member/2. This is equivalent to setting a spy point on member/2.