[Python-Dev] strop vs. string

Tim Peters tim.one@home.com
Sat, 26 May 2001 02:44:04 -0400


The buffer object has been neglected for years:  is that because it's in
prime shape, or because nobody cares about it enough to maintain it?  "The
bug" has been known for years without any action taken to address it; the
docs give up in spots and nobody addresses that either (like "The current
policy seems to state that these characters may be multi-byte characters" --
well, yes or no?); the builtin buffer() function isn't called anywhere in
the std test suite; the file object still has an undocumented readinto()
method that just confuses people who bump into it; and it's so obscure in
daily life that it appears Guido didn't even think of it when adding
iterators for the other sequence types.

I expect that answers my question <wink>.  Is someone (Greg? MAL?) going to
champion it now?  That would be cool.

About combining strop and buffers and strings, don't forget unicodeobject.c:
that's got oodles of basically duplicate code too.  /F suggested dealing
with the minor differences via maintaining one code file that gets compiled
multiple times w/ appropriate #defines.