Changes between Version 1 and Version 2 of ListsCowan


Ignore:
Timestamp:
11/23/12 02:40:45 (5 years ago)
Author:
cowan
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ListsCowan

    v1 v2  
    1919Returns `#t` if ''obj'' is the empty list, `#f` if ''obj'' is a pair.  It signals an error otherwise.  (Common Lisp ENDP.) 
    2020 
     21== Substitution == 
     22 
     23`(substitute `''newobj oldobj list''`)` 
     24 
     25`(substitute! `''newobj oldobj list''`)` 
     26 
     27`Substitute` returns a newly constructed list in which all elements of ''list'' that are the same (in the sense of `eqv?`) as ''oldobj'' have been replaced by ''newobj''.  `Substitute!` does the same thing, but may destructively modify ''list''.  (Common Lisp SUBSTITUTE, NSUBSTITUTE.) 
     28 
     29`(transform `''transformer predicate list''`)` 
     30 
     31`(transform! `''transformer predicate list''`)` 
     32 
     33`Transform` returns a newly constructed list in which all elements of ''list'' on which ''predicate'' returns `#t` have been replaced by the result of calling ''transformer'' on the element.  `Transform!` does the same, but may destructively modify ''list''.  (Closely related to Common Lisp SUBSTITUTE-IF, NSUBSTITUTE-IF.) 
     34 
    2135== Issues == 
    2236 
    23 Should these procedures, if accepted, be merged into SRFI 1? 
     37Should these procedures, if accepted, be merged into the SRFI 1 package?