[Python-ideas] Adding "+" and "+=" operators to dict
MRAB
python at mrabarnett.plus.com
Fri Feb 13 02:05:47 CET 2015
On 2015-02-12 21:56, Greg Ewing wrote:
> There's an obvious way out of all this. We add
> *two* new operators:
>
> d1 >> d2 # left operand wins
> d1 << d2 # right operand wins
>
Next people will be suggesting for an operator that subtracts the LHS
from the RHS!
> And if we really want to do it properly:
>
> d1 ^ d2 # raise exception on duplicate keys
>
More information about the Python-ideas
mailing list