Common Lisp the Language
2nd Edition

A large number of series functions are provided
because there are a
large number of useful operations that can be performed on series.
However
this functionality can be boiled down to a small
number of primitive constructs.
collecting-fn embodies the fundamental idea of series computations that utilize internal state. It can be used as the basis for defining any on-line transducer.
until embodies the fundamental idea of producing a series that is shorter than the shortest input series. In particular it embodies the idea of computing a bounded series from non-series inputs. Together with collecting-fn until can be used to define scan-fn which can be used as the basis for defining all the other scanners.
collect-last embodies the fundamental idea of producing a non-series value from a series. Together with collecting-fn it can be used to define collect-fn which (with the occasional assistance of until) can be used as the basis for defining all the other collectors.
producing embodies the fundamental idea of preorder computation. It can be used as the basis for defining all the other series functions can be used as the basis for defining all the other series functionstion. Itther/A>icons/next_motif.gif">