Mailing List Archive

Re: why
David Ascher wrote:
>
> Why does buffer(array('c', 'test')) return a read-only buffer?

Simply because the buffer() builtin always creates a read-only object,
rather than selecting read/write when possible.

Shouldn't be hard to alter the semantics of buffer() to do so. Maybe do
this at the same time as updating it to create read/write buffers out of
the blue.

Cheers,
-g

--
Greg Stein, http://www.lyra.org/