Skip to content

Commit d6c5ed5

Browse files
authored
Fix conditions lowering text for enums with no fields (rust-lang#2066)
1 parent acee479 commit d6c5ed5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/mir/construction.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ In [MIR] there is no difference between method calls and function calls anymore.
119119

120120
## Conditions
121121

122-
`if` conditions and `match` statements for `enum`s without variants with fields are
122+
`if` conditions and `match` statements for `enum`s with variants that have no fields are
123123
lowered to `TerminatorKind::SwitchInt`. Each possible value (so `0` and `1` for `if`
124124
conditions) has a corresponding `BasicBlock` to which the code continues.
125125
The argument being branched on is (again) an `Operand` representing the value of

0 commit comments

Comments
 (0)