On 2007-09-13, Stefan O'Rear <[EMAIL PROTECTED]> wrote:
> In any case, we already have hGetBuf / hPutBuf in the standard base
> libaries for raw binary IO, so code that uses getChar for bytes really
> has no excuse.

Except, of course, that hGetBuf and hPutBuf are
(a) allocating the memory for the buffers is a pain (does it require the
    FFI?)
(b) are something of a pain to use, requiring explicitly managing what's
    valid in these buffers (though a wrapper only need be written once)
(c) while in the "standard base libraries" are not in the report or
    library report.  i.e. there's no guarantee that a conforming Haskell
    implementation will have them.  It'd be silly for an implementation to
    not support them, of course, but...

The ByteString library at least fixes (a) and (b).

-- 
Aaron Denney
-><-

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to