Subject: Re: retract on static term

From: Jan Wielemaker <[email-masked]>
Date: Fri, 24 Mar 2000 16:10:45 +0100

On Fri, 24 Mar 2000, you wrote:
>Hi,
>may I pose the question directly to you?
>I changed from SWI-prolog 2.9. to 3.3. and now I get the following message.
>The retract-call on a static_procedure used to work in any case.
>
>ERROR: No permission to modify static_procedure `promisd:lex/2'
>^  Exception: (8) retractall(lex(_G3470)) ?
>
>Do I have to put a catch/3 around all the goals in order to avoid this?

There has been some discussion on this on the mailinglist.

Depends a lot what you want.  Do you want to get rid of the clauses
of lex/2?  Then use abolish/1.  Do you retract, but you are not sure
what you are retracting and you want to fail on static procedures?
Then using catch is a good choice.

Basically, catch is for dealing with things that may happen, you
don't really expect to happen but you do want to deal with it.

	Regards --- Jan