mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Patch by Serhiy Storchaka.
This commit is contained in:
parent
d0118e16a1
commit
3bbd2fad4d
3 changed files with 26 additions and 1 deletions
|
@ -702,6 +702,12 @@ class SizeofTest(unittest.TestCase):
|
|||
check(get_cell().__closure__[0], size(h + 'P'))
|
||||
# code
|
||||
check(get_cell().__code__, size(h + '5i9Pi3P'))
|
||||
check(get_cell.__code__, size(h + '5i9Pi3P'))
|
||||
def get_cell2(x):
|
||||
def inner():
|
||||
return x
|
||||
return inner
|
||||
check(get_cell2.__code__, size(h + '5i9Pi3P') + 1)
|
||||
# complex
|
||||
check(complex(0,1), size(h + '2d'))
|
||||
# method_descriptor (descriptor object)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue