Skip to content

Commit b1adb9d

Browse files
sobolevntushar-deepsource
authored andcommitted
Microrefactoring: py_version <= 2 should be py_version == 2 (python#11986)
1 parent 6c536e5 commit b1adb9d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mypy/checkexpr.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2205,7 +2205,7 @@ def visit_op_expr(self, e: OpExpr) -> Type:
22052205
return self.strfrm_checker.check_str_interpolation(e.left, e.right)
22062206
if isinstance(e.left, StrExpr):
22072207
return self.strfrm_checker.check_str_interpolation(e.left, e.right)
2208-
elif pyversion[0] <= 2:
2208+
elif pyversion[0] == 2:
22092209
if isinstance(e.left, (StrExpr, BytesExpr, UnicodeExpr)):
22102210
return self.strfrm_checker.check_str_interpolation(e.left, e.right)
22112211
left_type = self.accept(e.left)

0 commit comments

Comments
 (0)