mirror of
https://github.com/python/cpython.git
synced 2025-08-31 22:18:28 +00:00
bpo-46481: Implement vectorcall for weakref.ref.__call__ method. (GH-30820)
This commit is contained in:
parent
1f715d5bd3
commit
76dc047a0e
4 changed files with 35 additions and 52 deletions
|
@ -1538,11 +1538,11 @@ class SizeofTest(unittest.TestCase):
|
|||
# TODO: add check that forces layout of unicodefields
|
||||
# weakref
|
||||
import weakref
|
||||
check(weakref.ref(int), size('2Pn2P'))
|
||||
check(weakref.ref(int), size('2Pn3P'))
|
||||
# weakproxy
|
||||
# XXX
|
||||
# weakcallableproxy
|
||||
check(weakref.proxy(int), size('2Pn2P'))
|
||||
check(weakref.proxy(int), size('2Pn3P'))
|
||||
|
||||
def check_slots(self, obj, base, extra):
|
||||
expected = sys.getsizeof(base) + struct.calcsize(extra)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue