|
|
|
|
|
by masklinn
335 days ago
|
|
No no, do forget about it: like += for lists, |= mutates “the dict”, which often makes for awkward bugs. And like += over list.extend, |= over dict.update is very little gain, and restricts legal locations (augmented assignments are statements, method calls are expressions even if they return "nothing") |
|