From 879e23a02c746974e7318a26df9dd60cdf7fce95 Mon Sep 17 00:00:00 2001 From: Nikita Sobolev Date: Thu, 13 Jan 2022 17:39:16 +0300 Subject: [PATCH] Microrefactoring: `py_version <= 2` should be `py_version == 2` --- mypy/checkexpr.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mypy/checkexpr.py b/mypy/checkexpr.py index 391c7a59d60b..b05f9168ee12 100644 --- a/mypy/checkexpr.py +++ b/mypy/checkexpr.py @@ -2205,7 +2205,7 @@ def visit_op_expr(self, e: OpExpr) -> Type: return self.strfrm_checker.check_str_interpolation(e.left, e.right) if isinstance(e.left, StrExpr): return self.strfrm_checker.check_str_interpolation(e.left, e.right) - elif pyversion[0] <= 2: + elif pyversion[0] == 2: if isinstance(e.left, (StrExpr, BytesExpr, UnicodeExpr)): return self.strfrm_checker.check_str_interpolation(e.left, e.right) left_type = self.accept(e.left)