GH-128682: Make PyStackRef_CLOSE escaping. (GH-129404)

This commit is contained in:
Mark Shannon 2025-02-03 12:41:32 +00:00 committed by GitHub
parent 218f205f20
commit 808071b994
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 1348 additions and 657 deletions

View file

@ -538,7 +538,9 @@ class TestGeneratedCases(unittest.TestCase):
frame->instr_ptr = next_instr;
next_instr += 1;
INSTRUCTION_STATS(OP);
if (cond) goto label;
if (cond) {
goto label;
}
DISPATCH();
}
"""
@ -555,7 +557,9 @@ class TestGeneratedCases(unittest.TestCase):
frame->instr_ptr = next_instr;
next_instr += 1;
INSTRUCTION_STATS(OP);
if (cond) goto label;
if (cond) {
goto label;
}
// Comment is ok
DISPATCH();
}
@ -582,7 +586,9 @@ class TestGeneratedCases(unittest.TestCase):
right = stack_pointer[-1];
left = stack_pointer[-2];
SPAM(left, right);
if (cond) goto pop_2_label;
if (cond) {
goto pop_2_label;
}
res = 0;
stack_pointer[-2] = res;
stack_pointer += -1;
@ -611,7 +617,9 @@ class TestGeneratedCases(unittest.TestCase):
right = stack_pointer[-1];
left = stack_pointer[-2];
res = SPAM(left, right);
if (cond) goto pop_2_label;
if (cond) {
goto pop_2_label;
}
stack_pointer[-2] = res;
stack_pointer += -1;
assert(WITHIN_STACK_BOUNDS());
@ -1392,7 +1400,9 @@ class TestGeneratedCases(unittest.TestCase):
// THIRD
{
// Mark j and k as used
if (cond) goto pop_2_error;
if (cond) {
goto pop_2_error;
}
}
stack_pointer += -2;
assert(WITHIN_STACK_BOUNDS());