mirror of https://github.com/python/cpython
gh-88057: in compile.c, assertion that stackdepth is alway >=0 is missing in one place (GH-96513)
This commit is contained in:
parent
dde15f5879
commit
0cd992c000
|
@ -7075,6 +7075,7 @@ stackdepth(basicblock *entryblock, int code_flags)
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
int new_depth = depth + effect;
|
int new_depth = depth + effect;
|
||||||
|
assert(new_depth >= 0); /* invalid code or bug in stackdepth() */
|
||||||
if (new_depth > maxdepth) {
|
if (new_depth > maxdepth) {
|
||||||
maxdepth = new_depth;
|
maxdepth = new_depth;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue