Paul Sokolovsky wrote:
> Hello,
> On Mon, 30 Mar 2020 16:25:07 -0700
> Christopher Barker python...@gmail.com wrote:
> > As others have pointed out, the OP started in a  bit
> > of an oblique
> > way, but it maybe come down to this:
> > There are some use-cases for a mutable string type.
> > For avoidance of doubt: nothing in my RFC has anything to do, or
> implies, "a mutable string type". A well-know pattern of string
> builder, yes. Piggybacking on existing StringIO/BytesIO classes, yes.
> Anything else, no.
> To not leave it cut and dry: IMHO, we need more const'ness in Python,
> not less. I my dreams I already do stuff like:
> from __future__ import const
> class Foo:
>     pass
> # This is an alias for "Foo"
> Bar: const = Foo
> # This is a variable which can store a reference to Foo or any other class
> Baz = Foo
> [This is not a new RFC! Please start a new thread if you'd like to pick
> it up ;-)]

If I understand you are proposing a change from StringIO `write` method to `+=` 
operator. Is it right?

I cannot see any advantage on this proposal since there is no real change in 
the implementation of StringIO. Or are you proposing any change in the 
underlying implementation and I have missed that point?

In this case, I disagree with you: StringIO is a stream and I think that it is 
wrong to make it to "look & feel" like a string. That is my opinion.

Sorry if I misunderstand you.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/PHGIESG7VEBZZQGI2IZW7DHWH4MJWLOF/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to