On Jul 20, 2:57 am, casebash <walkr...@gmail.com> wrote:
> Hi,
>
> I have searched this list and found out that Python doesn't have a
> mutable string class (it had an inefficient one, but this was removed
> in 3.0). Are there any libraries outside the core that offer this?

I just did a brief search on Python Packaging Index (pypi.python.org)
and saw nothing.  You might have better luck.

I suspect there is not a mutable string class partly because there is
little demand, partly because it'd be hard to make an object that is
usable everywhere a string is.  For instance, a third-party string
object might not work with the re module.

The core does have some classes that are kind of like strings but
mutable.  The array module can create mutable arrays of characters
which are somewhat like strings.  Depending on your use case some
other things might suffice (such as mmap,  io.StringIO, or even a list
of characters).


Carl Banks
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to