Skip to content
This repository was archived by the owner on Oct 3, 2024. It is now read-only.

Commit c347dae

Browse files
Improve the rule decription
1 parent 5af5c98 commit c347dae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/rules/no-identical-conditions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# no-identical-conditions
22

33
A chain of `if-else-if` and `switch-case` statements is evaluated from top to bottom. At most, only
4-
one branch will be executed: the first one with a condition that evaluates to `true` or that matches the discriminant.
4+
one branch will be executed: the first one with a condition that evaluates to `true` or that matches the discriminant of the `switch`.
55

66
Therefore, duplicating a condition automatically leads to dead code. Usually, this is due to a
77
copy/paste error. At best, it's simply dead code and at worst, it's a bug that is likely to induce

0 commit comments

Comments
 (0)