Replace assert(0)
with Py_UNREACHABLE
in Python/symtable.c
#100577
Labels
interpreter-core
(Objects, Python, Grammar, and Parser dirs)
type-bug
An unexpected behavior, bug, or error
While looking at #87447 I've noticed that there are three places in
cpython
whereassert(0)
is used instead ofPy_UNREACHABLE
macro:cpython/Python/symtable.c
Lines 1539 to 1542 in 984894a
As the docs say:
The intent with
Py_UNREACHABLE
is clearer and error message is nicer.Linked PRs
assert(0)
withPy_UNREACHABLE
insymtable.c
#100579The text was updated successfully, but these errors were encountered: