PLOGHELP ABOLISH                                Robert Duncan, July 1993

Abolishing the definition of a predicate.

    ?- abolish(__Fn, _____Arity).


abolish/2 removes all trace of a definition for the predicate __Fn/_____Arity.
__Fn must be an atom (the functor name of the predicate) and _____Arity an
integer (its arity). You cannot abolish a system predicate.

Abolishing a predicate means:

    o   removing its procedure definition from the database

    o   cancelling any declared attributes

    o   removing any spy-point

abolish/2 will succeed for any valid predicate specification, even if
the predicate is currently undefined. Afterwards, predicate_info/2 will
report the predicate as:

    [undefined]

and calling it will raise an 'UNDEFINED PREDICATE' error.

abolish/2 differs from retractall/1 in that the latter merely retracts
all the clauses for a predicate: afterwards, the predicate will be
defined and dynamic but with no clauses, and calling it will always
fail.

The predicate prolog_abolish/2 is like abolish/2 but will also abolish
system predicates: see ________PLOGHELP * ______________PROLOG_ABOLISH.


See also:

________PLOGHELP * ______________PREDICATE_INFO
    Reporting the status of a predicate.

________PLOGHELP * __________RETRACTALL
    Retracting all the clauses for a predicate.

________PLOGHELP * _______UNKNOWN
    Changing the action taken when undefined predicates are called.


--- _______________________C.all/plog/help/abolish
--- _________Copyright __________University __of ______Sussex _____1993. ___All ______rights _________reserved.
