The Dogelog player provides already correct handling of a conjunction and disjunction of goals in a Prolog clause body or in a Prolog query. This also extends to the cut. The conjunction and disjunction do not have a direct built-in since they are translated into internals. In particular the cut is mapped to '$CUT'/1 with an additional argument.
Example:?- (X=1;X=2), !.
X = 1.
The interpreter has the capability to interrupt its control flow by exception handling. An interruption happens when an exception is thrown or when a signal is raised. An exception can be an arbitrary Prolog term. Some exception terms are recognized by the interpreter so as to display a user-friendly stack trace. In particular we recognize:
error(_, _)
warning(_, _)
cause(_, _)
The predicate throw/1 can be used to throw an exception. If the context is a variable the predi-cate will automatically instantiate the variable with the current stack trace. The predicate catch/1 can be used to catch a thrown exception. The predicate will only catch non-urgent exceptions and match the head of a chained exception.
The following control built-ins are provided: