]> granicus.if.org Git - python/commitdiff
make partialmethod example work (closes #21105)
authorBenjamin Peterson <benjamin@python.org>
Sun, 30 Mar 2014 19:07:09 +0000 (15:07 -0400)
committerBenjamin Peterson <benjamin@python.org>
Sun, 30 Mar 2014 19:07:09 +0000 (15:07 -0400)
Doc/library/functools.rst

index 77cd8384b1ff71d883a10ae6f5d2492a05424b56..c46b7997c1b41c654cb24d5b9deda32813d248ab 100644 (file)
@@ -218,6 +218,8 @@ The :mod:`functools` module defines the following functions:
    Example::
 
       >>> class Cell(object):
+      ...     def __init__(self):
+      ...         self._alive = False
       ...     @property
       ...     def alive(self):
       ...         return self._alive