Re: Minor comments on SRFI 121 "last call" draft.
John Cowan 23 Oct 2015 11:54 UTC
Sudarshan S Chawathe scripsit:
> I didn't understand it at this point (and so just skipped over,
> without any problems). It also took me a while to figure it out
> when I returned to it after reading the rest. An example near the
> end of the SRFI, where generator-unfold is defined, would be a big
> help, I think.
Example added that converts vectors to lists.
> * There is a typo "itt" in the Rationale text.
Fixed.
> * make-bits-generator: To check my understanding, there is no
> (simple) way to use this procedure to create a generator that
> gives a single 0 or 1 bit, correct?
That appears to be correct.
> * make-port-generator: I believe the bold instances of "port" in the
> description should read "input-port".
Fixed.
> * make-port-generator: The finiteness of the resulting generator
> also depends on 'reader', correct? It would probably be very odd,
> but the description seems to permit 'reader' to do things other
> than returning an eof-object when data from the port is exhausted.
Note to that effect added.
> * Is it true that there is no tail-call guarantee for gappend?
Correct.
> * Including duplicates in the example for gdelete may provide a
> better illustration of its action:
>
> (generator->list (gdelete (make-generator 1 2 3 4 5 3 6 7)))
> => (1 2 4 5 6 7)
Done.
> * Similar to above, to illustrate gdelete-neighbor-dups:
>
> (generator->list (gdelete-neighbor-dups
> (make-generator a a b c a a a d)))
> => (a b c a d)
Done.
> * gselect: Is there any guarantee regarding whether one generator
> will be called after the other has been exhausted? Perhaps it's
> unimportant; I don't have a use case in mind.
Guarantee added.
> * generator-unfold: An example would be very useful here to clarify
> matters, I think (related to the very first item above).
See above.
Again, thanks for the detailed review.
--
John Cowan http://www.ccil.org/~cowan xxxxxx@ccil.org
The peculiar excellence of comedy is its excellent fooling, and Aristophanes's
claim to immortality is based upon one title only: he was a master maker
of comedy, he could fool excellently. Here Gilbert stands side by side
with him. He, too, could write the most admirable nonsense. There has
never been better fooling than his, and a comparison with him carries
nothing derogatory to the great Athenian. --Edith Hamilton, The Greek Way