File "tools"

This files provides static clause inspection tools. Dogelog Player implements the strict policy that dynamic database predicates such as clause/2, assertz/1, etc..cannot access or modify static clauses, and that static clauses can only be modified through consult. To allow the user to inspect what has been consulted we provide the listing/[0,1] predicate.

The following tools predicates are provided:

listing:
listing(I):
The predicate lists the user clauses of the user predicates. The unary predicate allows specifying a predicate indicator.
term_singletons(T, L):
The built-in succeeds in L with the singleton variables of T.
nonground(T, V):
The built-in succeeds if T is non-ground and V is the first variable.
unnumbervars(S, N, T):
The predicate succeeds in T with a copy of S with compounds of the form ‘$VAR’(<index>) and <index> greater or equal N are replaced by fresh variables.

Kommentare