From 7a357ee7c448be52b522858d543f4d55e57ca456 Mon Sep 17 00:00:00 2001 From: Nick Drozd Date: Sat, 4 Jan 2025 22:41:10 -0600 Subject: [PATCH] Use single assignment for class var --- coverage/env.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/coverage/env.py b/coverage/env.py index a1d28983c..0944d64d5 100644 --- a/coverage/env.py +++ b/coverage/env.py @@ -53,10 +53,7 @@ class PYBEHAVIOR: # Is "if not __debug__" optimized away? The exact details have changed # across versions. - if pep626: - optimize_if_not_debug = 1 - else: - optimize_if_not_debug = 2 + optimize_if_not_debug = 1 if pep626 else 2 # 3.7 changed how functions with only docstrings are numbered. docstring_only_function = (not PYPY) and (PYVERSION <= (3, 10))