Kaydet (Commit) 46d3a595 authored tarafından Benjamin Peterson's avatar Benjamin Peterson

fix expected layout of code objects

üst 840ef8f8
...@@ -912,13 +912,13 @@ class SizeofTest(unittest.TestCase): ...@@ -912,13 +912,13 @@ class SizeofTest(unittest.TestCase):
return inner return inner
check(get_cell().__closure__[0], size('P')) check(get_cell().__closure__[0], size('P'))
# code # code
check(get_cell().__code__, size('5i9Pi3P')) check(get_cell().__code__, size('6i13P'))
check(get_cell.__code__, size('5i9Pi3P')) check(get_cell.__code__, size('6i13P'))
def get_cell2(x): def get_cell2(x):
def inner(): def inner():
return x return x
return inner return inner
check(get_cell2.__code__, size('5i9Pi3P') + 1) check(get_cell2.__code__, size('6i13P') + 1)
# complex # complex
check(complex(0,1), size('2d')) check(complex(0,1), size('2d'))
# method_descriptor (descriptor object) # method_descriptor (descriptor object)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment