On Fri, 29 Apr 2011 10:27:46 -0400, Roy Hyunjin Han 
<starsareblueandfara...@gmail.com> wrote:
> It would be convenient if replacing items in a dictionary returns the
> new dictionary, in a manner analogous to str.replace().  What do you
> think?

This belongs on python-ideas, but the short answer is no.  The
general language design principle (as I understand it) is that
mutable object do not return themselves upon mutation, while
immutable objects do return the new object.

--
R. David Murray           http://www.bitdance.com
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to