Re: Making immutable instances
- From: Mike Meyer <mwm@xxxxxxxxx>
- Date: Fri, 25 Nov 2005 20:50:41 -0500
Steven D'Aprano <steve@xxxxxxxxxxxxxxxxxxxxxx> writes:
> On Thu, 24 Nov 2005 11:44:16 -0500, Mike Meyer wrote:
>> In Python, I can even fix
>> it so *your* code uses my wrapped version:
>>
>> import Finney
>> class Addable(Finnney.Immutable): pass
>> Finney.Immutable = Addable
>
> Python's consenting adults philosophy allows the class designer some
> limited ability to force the class user to think about it before messing
> about with private variables. I think Ben's immutable class falls into
> that same category.
If you read the whole thread, you'll see that I don't have a problem
with messing with private variables. It's disallowing the addition of
new variables that I found objectionable.
<mike
--
Mike Meyer <mwm@xxxxxxxxx> http://www.mired.org/home/mwm/
Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.
.
- Follow-Ups:
- Re: Making immutable instances
- From: Steven D'Aprano
- Re: Making immutable instances
- References:
- Making immutable instances
- From: Ben Finney
- Re: Making immutable instances
- From: Alex Martelli
- Re: Making immutable instances
- From: Ben Finney
- Re: Making immutable instances
- From: Alex Martelli
- Re: Making immutable instances
- From: Ben Finney
- Re: Making immutable instances
- From: Mike Meyer
- Re: Making immutable instances
- From: Steven D'Aprano
- Making immutable instances
- Prev by Date: Re: drawline
- Next by Date: Re: wxPython Licence vs GPL
- Previous by thread: Re: Making immutable instances
- Next by thread: Re: Making immutable instances
- Index(es):