summaryrefslogtreecommitdiff
path: root/Lib/collections/__init__.py
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2011-06-02 23:49:44 -0700
committerRaymond Hettinger <python@rcn.com>2011-06-02 23:49:44 -0700
commit6135fb405a1c71f9fcbdb78ffc2886260fd462d5 (patch)
treee4023c6c2ff96bc5bf89d1eb501c909c28f3f014 /Lib/collections/__init__.py
parent05ce5fb4ed96f767d1168277f698ae6e969560d5 (diff)
parentb269df3dd7600f3c080956aaaa4961230398b56a (diff)
downloadcpython-6135fb405a1c71f9fcbdb78ffc2886260fd462d5.tar.gz
merge
Diffstat (limited to 'Lib/collections/__init__.py')
-rw-r--r--Lib/collections/__init__.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/collections/__init__.py b/Lib/collections/__init__.py
index 4b447ace34..03bd2b31ec 100644
--- a/Lib/collections/__init__.py
+++ b/Lib/collections/__init__.py
@@ -269,6 +269,8 @@ class {typename}(tuple):
'Return a new OrderedDict which maps field names to their values'
return OrderedDict(zip(self._fields, self))
+ __dict__ = property(_asdict)
+
def _replace(_self, **kwds):
'Return a new {typename} object replacing specified fields with new values'
result = _self._make(map(kwds.pop, {field_names!r}, _self))