summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2007-12-13 22:55:52 (GMT)
committerRaymond Hettinger <python@rcn.com>2007-12-13 22:55:52 (GMT)
commit04a9a0e904d31875bc7bbcbe0899076194d3cb6f (patch)
treec134bd02f47813c57fcd565b568d7c57320ddf1e /Doc/library
parente552959184ff58bfdcd72a6cc8d1460aaf82537d (diff)
downloadcpython-04a9a0e904d31875bc7bbcbe0899076194d3cb6f.zip
cpython-04a9a0e904d31875bc7bbcbe0899076194d3cb6f.tar.gz
cpython-04a9a0e904d31875bc7bbcbe0899076194d3cb6f.tar.bz2
Simplify implementation of __replace__()
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/collections.rst2
1 files changed, 1 insertions, 1 deletions
diff --git a/Doc/library/collections.rst b/Doc/library/collections.rst
index 403d00f..fc52408 100644
--- a/Doc/library/collections.rst
+++ b/Doc/library/collections.rst
@@ -396,7 +396,7 @@ Example::
return dict(zip(('x', 'y'), self))
def __replace__(self, **kwds):
'Return a new Point object replacing specified fields with new values'
- return Point(**dict(zip(('x', 'y'), self) + kwds.items()))
+ return Point(**dict(zip(('x', 'y'), self), **kwds))
x = property(itemgetter(0))
y = property(itemgetter(1))