Michele Simionato wrote:
>> >>> A = []  # let's declare a "constant" here
>> >>> b = A   # and let's assign the constant here
>> >>> b.append('1') # OOPS!
> 
> But it makes no sense to use a mutable object for a constant!
> The user should use a tuple, 

Sure.  Now show me the builtin immutable equivalent of a dict.

> or a custom list-like type where 
> all methods with side effects are removed, so it effectively acts
> as a tuple.

Ugh, not worth the trouble imo.


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

Reply via email to