Am 10.01.2013 13:57, schrieb eryksun:
That should be

     cls.method_list[0].__get__(None, cls)()

The way you have it binds the method to type(MyClass), which in this
case is "type" itself. See cm_descr_get in funcobject.c, CPython 2.7
(line 645):

http://hg.python.org/cpython/file/70274d53c1dd/Objects/funcobject.c#l635

Also see the slot wrapper wrap_descr_get for the mapping from None to
NULL (line 4671):

http://hg.python.org/cpython/file/70274d53c1dd/Objects/typeobject.c#l4660
This works. Thanks!
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to