
Feb. 13, 2015
12:21 a.m.
On 02/12/2015 04:19 PM, Eric Snow wrote:
On Thu, Feb 12, 2015 at 4:29 PM, Donald Stufft <donald@stufft.io> wrote:
On Feb 12, 2015, at 6:28 PM, Eric Snow <ericsnowcurrently@gmail.com> wrote: copy-and-update:
dict(old_dict, **other_dict)
Only works if other_dict’s keys are all valid keyword arguments and AFAIK is considered an implementation detail of CPython.
Fair point. It seems to me that there is definitely enough interest in a builtin way of doing this. My vote is for a dict classmethod.
Like __add__, for example? ;) -- ~Ethan~