mirror of
https://github.com/python/cpython.git
synced 2025-11-01 10:45:30 +00:00
SF patch 537536 by Phillip J. Eby, fix for SF bug 535444, super()
broken w/ classmethods. Bugfix candidate.
This commit is contained in:
parent
103b548a76
commit
155db9aa22
2 changed files with 15 additions and 3 deletions
|
|
@ -1214,6 +1214,14 @@ def classmethods():
|
|||
vereq(ff.__get__(0, int)(42), (int, 42))
|
||||
vereq(ff.__get__(0)(42), (int, 42))
|
||||
|
||||
# Test super() with classmethods (SF bug 535444)
|
||||
veris(C.goo.im_self, C)
|
||||
veris(D.goo.im_self, D)
|
||||
veris(super(D,D).goo.im_self, D)
|
||||
veris(super(D,d).goo.im_self, D)
|
||||
vereq(super(D,D).goo(), (D,))
|
||||
vereq(super(D,d).goo(), (D,))
|
||||
|
||||
def classmethods_in_c():
|
||||
if verbose: print "Testing C-based class methods..."
|
||||
import xxsubtype as spam
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue