discontinuous predicate warning from gnuprolog v1.3.0

Bernardo Elayda <[email protected]>
Newsgroups gmane.comp.gnu.prolog.general
Message-ID <[email protected]>
Hello,

I'm trying to use this very simple Prolog testcase with Gnu Prolog v1.3.0:

     1 listensToMusic(mia).
     2 happy(yolanda).
     3 playsAirGuitar(mia) :- listensToMusic(mia).
     4 playsAirGuitar(yolanda) :- listensToMusic(yolanda).
     5 listensToMusic(yolanda):- happy(yolanda).

When the above code is loaded(w/o the line numbers), the interpreter says:

| ?- [kb2].
compiling /home/captain/Junk/kb2.pl for byte code...
/home/captain/Junk/kb2.pl:5: warning: discontiguous predicate
listensToMusic/1 - clause ignored
/home/captain/Junk/kb2.pl compiled, 5 lines read - 729 bytes written, 6 ms

And if one runs the query playsAirGuitar(yolanda), the knowledge base did
ignore clause number 5.  What is wrong with line number 5?
This same testcase with other versions of Prolog is processed correctly;
clause number 5 isn't ignored.

tia,
Bernie

_______________________________________________
Users-prolog mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/users-prolog
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.