GH-108614: Add RESUME_CHECK instruction (GH-108630)

This commit is contained in:
Mark Shannon 2023-09-07 14:39:03 +01:00 committed by GitHub
parent d485551c9d
commit 0858328ca2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 519 additions and 482 deletions

View file

@ -333,7 +333,11 @@ gen_close_iter(PyObject *yf)
static inline bool
is_resume(_Py_CODEUNIT *instr)
{
return instr->op.code == RESUME || instr->op.code == INSTRUMENTED_RESUME;
return (
instr->op.code == RESUME ||
instr->op.code == RESUME_CHECK ||
instr->op.code == INSTRUMENTED_RESUME
);
}
static inline bool