Per Bothner <[EMAIL PROTECTED]> writes:

> It is unclear to me how one would implement get-bytevector-some.
> I don't think it can be implemented reasonably using the read
> call-back function of make-custom-binary-port.  The best I can think
> of: allocated some largish buffer, call the read call-back, and
> the re-allocate a new bytevector with however many bytes were
> actually read.  But that still won't return "a freshly allocated
> bytevector of non-zero size containing the available data" -
> just "a freshly allocated bytevector of non-zero size containing
> *part* of the available data".

That depends on your notion of "available data", but I agree it should
be clarified.

> And it means allocating a temporary large bytevector and throwing it
> away.

That depends on your implementation: You storage manager might allow
you to allocate a large object and reduce its size later.  (The Scheme
48 GC actually behaves this way.)

-- 
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla

_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to