Re: permission error
Cliff Bender <[email protected]>
| Newsgroups | gmane.comp.gnu.prolog.general |
|---|---|
| Message-ID | <[email protected]> |
After you told me, Ali, I dug deeper and found the source of the problem. It appears the example is using SWI-Prolog or similar and not gprolog, and clause/2 is built in and described as: *clause*(?Head, ?Body) Succeeds when Head can be unified with a clause head and Body with the corresponding clause body. Gives alternative clauses on backtracking. For facts Body is unified with the atom true. Normally clause/2 is used to find clause definitions for a predicate, but it can also be used to find clause heads for some body template. does anyone know a site somewhere i can find examples and tutorials that use gprolog instead of swi or some other flavor? It would minimize my constant questions... thanks, Cliff On 9/19/05, ED-DBALI AbdelAli <[email protected]> wrote: > > Cliff Bender a écrit : > > ... > > clause_tree(G) :- > > clause(G,Body), > > clause_tree(Body). /* grow branches */ > > ... > > Does anybody have any idea? member is a built-in with gprolog (i know > > this because i tried to define one, and it says so) and i'm not calling > > clause/2, but clause_tree/2. > > Hi, > > You are calling clause/2 in de last clause : clause(G,Body) !! > That's why you got the error. > > Ali. > > --------------------------------------------------------------- > AbdelAli ED-DBALI, Maître de conférences (Informatique) > LIFO, Université d'Orléans > http://www.univ-orleans.fr/lifo/Membres/eddbali > --------------------------------------------------------------- > > _______________________________________________ Users-prolog mailing list [email protected] http://lists.gnu.org/mailman/listinfo/users-prolog