---
source: crates/ruff_linter/src/rules/ruff/mod.rs
---
RUF047 [*] Empty `else` clause
 --> RUF047_if.py:5:1
  |
3 |   if False:
4 |       condition_is_not_evaluated()
5 | / else:
6 | |     pass
  | |________^
  |
help: Remove the `else` clause
  |
4 |     condition_is_not_evaluated()
  - else:
  -     pass
5 |
  |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:11:1
   |
 9 |   if this_comment():
10 |       belongs_to()  # `if`
11 | / else:
12 | |     ...
   | |_______^
   |
help: Remove the `else` clause
   |
10 |     belongs_to()  # `if`
   - else:
   -     ...
11 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:19:1
   |
17 |   elif the_same():
18 |       as_if()
19 | / else:
20 | |     pass
   | |________^
   |
help: Remove the `else` clause
   |
18 |     as_if()
   - else:
   -     pass
19 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:26:1
   |
24 |       belongs()  # to
25 |         # `if`
26 | / else:
27 | |     pass
   | |________^
28 |
29 |   if this_second_comment():
   |
help: Remove the `else` clause
   |
25 |       # `if`
   - else:
   -     pass
26 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:32:1
   |
30 |       belongs()  # to
31 |       # `if`
32 | / else:
33 | |     pass
   | |________^
   |
help: Remove the `else` clause
   |
31 |     # `if`
   - else:
   -     pass
32 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:44:1
   |
43 | if of_course: this()
44 | else: ...
   | ^^^^^^^^^
   |
help: Remove the `else` clause
   |
43 | if of_course: this()
   - else: ...
44 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:49:1
   |
47 | if of_course:
48 |     this() # comment
49 | else: ...
   | ^^^^^^^^^
   |
help: Remove the `else` clause
   |
48 |     this() # comment
   - else: ...
49 |
   |

RUF047 [*] Empty `else` clause
  --> RUF047_if.py:55:5
   |
53 |       if a:
54 |           b()
55 | /     else:
56 | |         ...
   | |___________^
   |
help: Remove the `else` clause
   |
54 |         b()
   -     else:
   -         ...
55 |
   |
