Revision 3716
Added by Aaron Marcuse-Kubitza over 12 years ago
lib/dicts.py | ||
---|---|---|
8 | 8 |
class DictProxy(UserDict.DictMixin): |
9 | 9 |
'''A proxy that forwards all accesses to an inner dict.''' |
10 | 10 |
|
11 |
def __init__(self, inner): self.inner = inner |
|
11 |
def __init__(self, inner={}): self.inner = inner
|
|
12 | 12 |
|
13 | 13 |
def keys(self): return self.inner.keys() |
14 | 14 |
|
Also available in: Unified diff
dicts.py: DictProxy: Added default value for inner param to facilitate creating empty wrapped dicts