This chapter defines the terminology which is used throughout the manual and in related documentation.
or simplyGoal_1, Goal_2, ..., Goal_k
Each Goal_i must be a callable term.Goal
where f is the functor of the compound term, n is its arity and t_i are terms. Lists and pairs are also compound terms.f(t_1, t_2, ..., t_n)
This classification is borrowed from the Mercury programming language, but in ECLiPSe only used for the purpose of documentation. Note that the determinism of a predicate usually depends on its calling mode.| Maximum number of solutions Can fail? | 0 1 > 1 ------------+------------------------------------------ no | erroneous det multi yes | failure semidet nondet
where Head is a head.Head.
A fact may be considered to be a rule whose body is always true.
is shorthand for:[a , b , c]
[a | [b | [c | []]]]
where the symbols +, ++, - and ? represent instantiated, ground, uninstantiated and unknown arguments respectively.p(+,-)
H is the head of the pair and T its tail.[H|T]
(i.e., a compound term with the functor :-/2), or only a fact.Head :- Body.
or:- Goal_1, ..., Goal_k.
The first of these two forms is often called a directive.?- Goal_1, ..., Goal_k.
A regular (Prolog) procedure is a sequence of user clauses whose heads have the same functor, which then identifies the user procedure.
The SpecList notation is used in many built-ins, for example, to specify a list of procedures in the export/1 predicate.name_1/arity_1, name_2/arity_2, ..., name_k/arity_k.
The notation Pred/N1, N2 is often used in this documentation as a shorthand for Pred/N1, Pred/N2.