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

correspondences with SRFI-1



I am not a stream expert, so I will concentrate on interface design
questions. This _lazy list SRFI_ should IMHO be closer to the popular
_list SRFI_ (SRFI-1).

Here are my comments in textual order:

Drop:
stream-take-until, stream-drop-until
(No equivalent in SRFI-1 and stream-take-while/stream-drop-while
might suffice.)

Rename:
stream-split       -> stream-split-at
stream-split-until -> stream-break
stream-split-while -> stream-span

The one line definition of stream-partition seems to be incomplete.

Rename:
stream-fold-left -> stream-fold
(Is the order of arguments for func reversed compared to SRFI-1?)
stream-scan... -> ...? (fold-pair...?, is this the corresponding function?)
stream-fold-..-one -> stream-reduce (with slightly different semantics!)

Restricted usefulness:
port->word-stream (because it relies on char-alphabetic?, similarly for
port->line-stream
How about a predicate for characters as an argument?

Rename:
stream-concat -> stream-concatenate
... and probably some more ...
You get the idea what I am after :-)

And:
People should report functions (inspired by SRFI-1) that
- make sense for streams AND
- are currently not in SRFI-40.

Greetings
Sven