|Did you know ...||Search Documentation:|
|Declaring predicate properties|
This section describes directives which manipulate attributes of predicate definitions. The functors dynamic/1, multifile/1, discontiguous/1 and public/1 are operators of priority 1150 (see op/3), which implies that the list of predicates they involve can just be a comma-separated list:
:- dynamic foo/0, baz/2.
In SWI-Prolog all these directives are just predicates. This implies they can also be called by a program. Do not rely on this feature if you want to maintain portability to other Prolog implementations.
non_terminalattribute on the predicate. This indicates that the predicate implements a grammar rule. Currently, predicates that are exported using Name//Arity syntax are flagged as non-terminals. Ideally we should add this flag to any predicate created from the expansion of a
rule, but that is difficult without breaking compatibility for programs that reason about expand_term/2,4.