Skip to content

Commit

Permalink
bpo-30709: Improve code example in Descriptor HowTo doc (GH-2339)
Browse files Browse the repository at this point in the history
  • Loading branch information
anqurvanillapy authored and Mariatta committed Jun 23, 2017
1 parent ea00798 commit b066edf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Doc/howto/descriptor.rst
Expand Up @@ -252,10 +252,10 @@ to wrap access to the value attribute in a property data descriptor::

class Cell(object):
. . .
def getvalue(self, obj):
"Recalculate cell before returning value"
def getvalue(self):
"Recalculate the cell before returning value"
self.recalc()
return obj._value
return self._value
value = property(getvalue)


Expand Down

0 comments on commit b066edf

Please sign in to comment.