gh-106797: Remove warning logs from Python/generated_cases.c.h and executor_cases.c.h (gh-107889)

gh-106797: Remove warning logs from Python/generated_cases.c.h
This commit is contained in:
Dong-hee Na 2023-08-13 04:36:46 +09:00 • committed by GitHub
parent 2e1f688fe0
commit bf707749e8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View file

@ -61,14 +61,14 @@ class StackOffset:
for eff in self.deep:
if eff.size:
terms.append(("-", maybe_parenthesize(eff.size)))
elif eff.cond and eff.cond != "1":
elif eff.cond and eff.cond not in ("0", "1"):
terms.append(("-", f"({parenthesize_cond(eff.cond)} ? 1 : 0)"))
elif eff.cond != "0":
num -= 1
for eff in self.high:
if eff.size:
terms.append(("+", maybe_parenthesize(eff.size)))
elif eff.cond and eff.cond != "1":
elif eff.cond and eff.cond not in ("0", "1"):
terms.append(("+", f"({parenthesize_cond(eff.cond)} ? 1 : 0)"))
elif eff.cond != "0":
num += 1