From 7ed6f7ead19c81d697e0364ac849bd042b7f1502 Mon Sep 17 00:00:00 2001 From: Raymond Hettinger Date: Sun, 10 Mar 2013 09:49:08 -0700 Subject: Classmethod example needs to inherit from object --- Doc/howto/descriptor.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/howto/descriptor.rst b/Doc/howto/descriptor.rst index 0db96d6..f793562 100644 --- a/Doc/howto/descriptor.rst +++ b/Doc/howto/descriptor.rst @@ -409,7 +409,7 @@ is to create alternate class constructors. In Python 2.3, the classmethod :func:`dict.fromkeys` creates a new dictionary from a list of keys. The pure Python equivalent is:: - class Dict: + class Dict(object): . . . def fromkeys(klass, iterable, value=None): "Emulate dict_fromkeys() in Objects/dictobject.c" -- cgit v0.12