We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c951668 commit d356fb0Copy full SHA for d356fb0
Lib/test/test_capi/test_opt.py
@@ -4051,8 +4051,8 @@ def testfunc(n):
4051
def test_binary_subscr_list_slice(self):
4052
def testfunc(n):
4053
x = 0
4054
+ l = [1, 2, 3]
4055
for _ in range(n):
- l = [1, 2, 3]
4056
x += l[0:1][0]
4057
return x
4058
@@ -4062,8 +4062,8 @@ def testfunc(n):
4062
4063
self.assertIn("_BINARY_OP_SUBSCR_LIST_SLICE", uops)
4064
self.assertNotIn("_GUARD_TOS_LIST", uops)
4065
- self.assertEqual(count_ops(ex, "_POP_TOP"), 3)
4066
- self.assertEqual(count_ops(ex, "_POP_TOP_NOP"), 5)
+ self.assertEqual(count_ops(ex, "_POP_TOP"), 2)
+ self.assertEqual(count_ops(ex, "_POP_TOP_NOP"), 4)
4067
4068
def test_is_op(self):
4069
def test_is_false(n):
0 commit comments