[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Malformed do loops



    Date: 21 April 1981 08:15-EST
    From: Robert W. Kerns <RWK at MIT-MC>

        Date: 17 April 1981 17:31-EST
        From: Alan Bawden <ALAN at MIT-MC>
        Subject: Malformed do loops
        To: MOON at MIT-MC
        cc: BUG-lmman at MIT-AI, BUG-lispm at MIT-AI

	    Date: 17 April 1981 16:04-EST
	    From: David A. Moon <MOON at MIT-MC>

From: 		ALAN@MIT-MC
Date: Thu, 17 Apr 81 11:29:03 GMT
Original-Date: 04/17/81 07:29:03 EDT
Subject:
		To: (BUG lmman) at MIT-AI
		The do loops in both of the samefringe functions in the stack-group
		documentation examples, are malformed.  (pages 154 and 155)

	    No they aren't.  This is an incompatibility between Lisp machine
	    and Maclisp.  That code was tested by running it directly out of
	    the source file of the manual by the way.
        
        Well that's a shame.  Could we get it changed back?  Doesn't anyone
        else ever mis-type the number of parens in a do loop out there?  I
        sure am surprised I haven't noticed this before given the number of
        times I make the error.

    Huh?  Am I confused or are you two?  As near as I can figure, both DO loops
    are perfectly legal in both LISPM and MacLisp.  Or are you refering to
    something else besides the atomic index variable specification?

Well, well.  MacLisp does seem to try and support this losing feature:

(putprop 'v1 'foo 'bar)
FOO 
(do (v1 v2) (nil) (print (list v1 v2)))
(NIL NIL) 		;first time around v1 and v2 bound to nil
;FOO UNBOUND VARIABLE	;(caddr 'v1) is FOO!

;BKPT UNBOUND-VARIABLE