scheme/list requests [was: Re: [plt-dev] Re: more requests for typed-scheme]
At Sat, 2 May 2009 19:47:42 -0400, Eli Barzilay wrote:
> This is from the rrrs-authors list (from Will):
>
> Non-controversial #1:
> I object to make-list, list-fill!, list-set!, and list-copy on the
> grounds that they are useful only for side-effect-full programming on
> lists, which I claim is an unusual style that the standard should not
> encourage. The corresponding procedures for strings and vectors are
> less objectionable because side-effect-full programming on strings
> and vectors is normal in Scheme. [...]
It turns out that Will was wrong with respect to `make-list', since
David found lots of good functional uses of `make-list'.
At Sat, 2 May 2009 20:16:00 -0400, Eli Barzilay wrote:
> > When we have a function that we can easily add to a library, and
> > that would simplify multiple pieces of code we write, we should add
> > it. I don't see why there's a debate about this.
>
> There are orders of magnitude more functions that fall in this
> category and are not added to the libraries, so there is obviously a
> debate.
Yes, there should be a debate, since the cost of each function is more
code, more tests, and more documentation.
I lean on the side of inclusion. It's used more in our own sources than
I would have guessed, and adding it would be more consistent with the
other `make-' functions.