Alexandre Vassalotti <[email protected]> added the comment:
I am against adding __add__ to dict, since merging dictionaries is not a
commutative operation.
If a short syntax is desired for merging dictionaries, the just define a
function. For example:
def merge_dicts(*args):
result = {}
for x in args:
result.update(x)
return result
----------
nosy: +alexandre.vassalotti
resolution: -> rejected
status: open -> pending
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue6410>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com