Antoine Pitrou wrote: > Well... It really depends what kind of problem you're solving. I > certainly delete or pop items from dicts quite often. > > Let's not claim that deleting items from a dict is a rare or advanced > feature. It is not. +1. It's a pretty common pattern for handling optional keyword arguments, e.g. in subclass methods. class Foo(Bar): def foo(self, *args **kws): mine = kws.pop('mine', None) super().foo(self, *args, **kws) do_something_myself(mine) Now the question is, what guarantees does the language make about the ordering of kws that Foo.foo() is passing to Bar.foo()? -Barry
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4