Small improvement to the implementation of __replace__().
diff --git a/Lib/collections.py b/Lib/collections.py
index 6b2e58d..7381a3a 100644
--- a/Lib/collections.py
+++ b/Lib/collections.py
@@ -64,7 +64,7 @@
return dict(zip(%(field_names)r, self))
def __replace__(self, **kwds):
'Return a new %(typename)s object replacing specified fields with new values'
- return %(typename)s(**dict(self.__asdict__().items() + kwds.items())) \n''' % locals()
+ return %(typename)s(**dict(zip(%(field_names)r, self) + kwds.items())) \n''' % locals()
for i, name in enumerate(field_names):
template += ' %s = property(itemgetter(%d))\n' % (name, i)
if verbose: