Skip to content

Commit 59e3247

Browse files
committed
Address code review
1 parent f479fc6 commit 59e3247

File tree

6 files changed

+17
-15
lines changed

6 files changed

+17
-15
lines changed

Include/internal/pycore_opcode_metadata.h

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Include/internal/pycore_uop_metadata.h

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/bytecodes.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ dummy_func(
365365
}
366366

367367
op(_POP_TOP_UNICODE, (value --)) {
368-
assert(PyUnicode_Check(PyStackRef_AsPyObjectBorrow(value)));
368+
assert(PyUnicode_CheckExact(PyStackRef_AsPyObjectBorrow(value)));
369369
PyStackRef_CLOSE_SPECIALIZED(value, _PyUnicode_ExactDealloc);
370370
}
371371

@@ -753,7 +753,9 @@ dummy_func(
753753
l = left;
754754
r = right;
755755
INPUTS_DEAD();
756-
ERROR_IF(res_o == NULL);
756+
if (res_o == NULL) {
757+
ERROR_NO_POP();
758+
}
757759
res = PyStackRef_FromPyObjectSteal(res_o);
758760
}
759761

Python/executor_cases.c.h

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/generated_cases.c.h

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/optimizer_cases.c.h

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)