diff options
| author | Georg Brandl <georg@python.org> | 2009-02-28 21:35:59 (GMT) |
|---|---|---|
| committer | Georg Brandl <georg@python.org> | 2009-02-28 21:35:59 (GMT) |
| commit | 9bb9f12266a19a72ab8e9921fddb0de6da48ee74 (patch) | |
| tree | f64505824366db9b8c39dc474e0ddc5328c8c752 /Lib/abc.py | |
| parent | b896614cd97c1185d57b98f05134d72f96da3ee1 (diff) | |
| download | cpython-9bb9f12266a19a72ab8e9921fddb0de6da48ee74.zip cpython-9bb9f12266a19a72ab8e9921fddb0de6da48ee74.tar.gz cpython-9bb9f12266a19a72ab8e9921fddb0de6da48ee74.tar.bz2 | |
Merged revisions 70078 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r70078 | georg.brandl | 2009-02-28 22:33:10 +0100 (Sa, 28 Feb 2009) | 2 lines
Fix 3k-style metaclass syntax in docstrings.
........
Diffstat (limited to 'Lib/abc.py')
| -rw-r--r-- | Lib/abc.py | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -15,7 +15,8 @@ def abstractmethod(funcobj): Usage: - class C(metaclass=ABCMeta): + class C: + __metaclass__ = ABCMeta @abstractmethod def my_abstract_method(self, ...): ... @@ -35,7 +36,8 @@ class abstractproperty(property): Usage: - class C(metaclass=ABCMeta): + class C: + __metaclass__ = ABCMeta @abstractproperty def my_abstract_property(self): ... @@ -43,7 +45,8 @@ class abstractproperty(property): This defines a read-only property; you can also define a read-write abstract property using the 'long' form of property declaration: - class C(metaclass=ABCMeta): + class C: + __metaclass__ = ABCMeta def getx(self): ... def setx(self, value): ... x = abstractproperty(getx, setx) |
