| |||||||||||
| deletes from the database all clauses which head is unifiable with the argument.
retractall(+Head)
retractall/1 deletes all clauses from the database which
head is unifiable with Head.
retractall(Head) :- retract((Head :- _)), fail.
Arguments
Head head of a clause
Examples
Assume that the database contains the clauses:
colour(blue).
colour(yellow).
colour(blue,yellow,green).
add(X,Y,Z) :- Z is X+Y.
f(a).
f(a) :- b.
Standard
This predicate is not part of the ISO-Prolog Standard.
See alsoasserta/1, assertz/1, abolish/1, collect/3, load/1, unload/1, load/1/2, retract/1. | |||||||||||
| |||||||||||
| Back> |
|