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

PLEASE???



Will somebody please fix this? PLEASE?? This ==> BUG <== hit me
today, and most people compile their code for speed.


     Date: 16 Jan 1981 0319-PST
     From: Rod Brooks <ROD at SU-AI>
     Subject: COMPLR can't do DO 
     To:   bug-lisp at MIT-MC    

     I have vague memories of complaining about something like this years ago
     but maybe this is different. In any case I wish it didn't happen this way.

     (defun baz (n)
	    (do ((old 1 new)
		 (new 2 (1+ new))
		 (l () (cons (list old new) l))
		 (i 0 (1+ i)))
		((= i n) l)))

     interpreted:
     (baz 4) ==> ((4 5) (3 4) (2 3) (1 2)) 

     compiled (both 905 and 924):
     (baz 4) ==> ((5 5) (4 4) (2 3) (1 2)) 

Perhaps COMPLR thinks it is too smart.