🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.lang.prolog
3 messages
3 total messages Started by Trinity College Dublin Ireland M... Mon, 31 Aug 1992 09:29
Errors in ISO Prolog Draft?
#750
Author: Trinity College Dublin Ireland M...
Date: Mon, 31 Aug 1992 09:29
16 lines
1072 bytes
I am trying to implement disjunction, if-then, if-then-else and
negation-by-failure according to ISO Prolog Draft of March 27, 1992, and I
think there may be some mistakes in the examples. Can anyone comment?

The mistakes (?) are:

Section 7.8.7.2. This is examples of if-then. The second-last example
appears to have a syntax error. I won't lose sleep worrying about that one.

Section 7.8.8.2. This is examples of if-then-else. I just don't see how the
stated behaviour of the last example can conform to the intended operation
of if-then-else. This one I worry about.

Can anyone help?

Mike
Re: Errors in ISO Prolog Draft?
#751
Author: Mats Carlsson
Date: Tue, 01 Sep 1992 07:42
22 lines
1531 bytes
In article <Trinity-College-Dublin--Ireland-310892103019@brady.cs.tcd.ie> Trinity College Dublin, Ireland (Michael Brady) writes:

   I am trying to implement disjunction, if-then, if-then-else and
   negation-by-failure according to ISO Prolog Draft of March 27, 1992, and I
   think there may be some mistakes in the examples. Can anyone comment?

   The mistakes (?) are:

   Section 7.8.7.2. This is examples of if-then. The second-last example
   appears to have a syntax error. I won't lose sleep worrying about that one.

Yes, the parentheses don't match.

   Section 7.8.8.2. This is examples of if-then-else. I just don't see how the
   stated behaviour of the last example can conform to the intended operation
   of if-then-else. This one I worry about.

Don't worry.  The example should fail on backtracking.
--
Mats Carlsson
SICS, PO Box 1263, S-164 28  KISTA, Sweden    Internet: matsc@sics.se
Tel: +46 8 7521543     Ttx: 812 6154 7010 SICS     Fax: +46 8 7517230
Re: Errors in ISO Prolog Draft?
#755
Author: David Bowen
Date: Tue, 01 Sep 1992 18:28
25 lines
1718 bytes
In article <Trinity-College-Dublin--Ireland-310892103019@brady.cs.tcd.ie>, Trinity College Dublin, Ireland (Michael Brady) writes:
> I am trying to implement disjunction, if-then, if-then-else and
> negation-by-failure according to ISO Prolog Draft of March 27, 1992, and I
> think there may be some mistakes in the examples. Can anyone comment?
> 
> The mistakes (?) are:
> 
> Section 7.8.7.2. This is examples of if-then. The second-last example
> appears to have a syntax error. I won't lose sleep worrying about that one.

Yes, this looks like a syntax error to me too.  It will be fixed.

> Section 7.8.8.2. This is examples of if-then-else. I just don't see how the
> stated behaviour of the last example can conform to the intended operation
> of if-then-else. This one I worry about.

You are right.  The example is wrong.  In the October 91 draft (N84) this 
same example was given (7.7.8.2) with the correct result -- it only succeeds 
once.

-- 
David Bowen				Vice President Product Engineering
Quintus Corporation                     InterNet:       dbowen@quintus.com
2100 Geng Road                          FAX:            415 494 7608
Palo Alto, California 94303             Phone:          415 813 3800
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads