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

Re: DOLIST, with index variable

    Date: 20 March 1981 23:04-EST
    From: Robert W. Kerns <RWK at MIT-MC>
    I think GLS's idea is far more useful than NIL's (unnounced,
    undiscussed, added-by-person-who-wrote-the-code) feature of
    DOLIST taking a "count" argument in that position.
DOLIST has never been specifically part of the NIL design, but NIL would
logically inherit it from MacLISP.  There was a version of DOLIST in MacLISP's 
UMLMAC file, which was inserted by someone (?? who?) between the LISP RECENT 
note of FEB 07,1980 and Oct 1980.  So  I documented what I found in UMLMAC,
in the LISP RECENT note of Oct 28,1980, and 
proceeded to use it;  I suspect other people have used it too, for it is an 
extremely common case to want to map down a list knowing the index of the 
element your are working on.  So common, in fact, that if it has to be 
retroactively excised from MacLISP/NIL for compatibility with whomever, then 
we'll simply have to invent some other name for it (e.g., DOLISTIMES !)
    As MOON has pointed out, there are already three entirely reasonable, 
unfortunately incompatible, proposed extensions for DOLIST; so no matter 
what standard could be chosen for DOLIST now, it would probably inconvenience