Skip to content

Commit

Permalink
Refactor: Remove redundant if check
Browse files Browse the repository at this point in the history
  • Loading branch information
NMertsch committed Sep 9, 2024
1 parent 8be7411 commit 27b2c57
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mypy/partially_defined.py
Original file line number Diff line number Diff line change
Expand Up @@ -594,8 +594,7 @@ def visit_while_stmt(self, o: WhileStmt) -> None:
if has_break:
self.tracker.start_branch_statement()
self.tracker.next_branch()
if o.else_body:
o.else_body.accept(self)
o.else_body.accept(self)
if has_break:
self.tracker.end_branch_statement()
self.loops.pop()
Expand Down

0 comments on commit 27b2c57

Please sign in to comment.