Skip to content

Commit 03c58d0

Browse files
authored
Rollup merge of #145119 - makai410:pretty-fix, r=compiler-errors
rustc_public: fix missing parenthesis in pretty discriminant
2 parents 13001b2 + 7429b1a commit 03c58d0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/mir/pretty.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ fn pretty_statement<W: Write>(writer: &mut W, statement: &StatementKind) -> io::
100100
writeln!(writer, "{INDENT}FakeRead({cause:?}, {place:?});")
101101
}
102102
StatementKind::SetDiscriminant { place, variant_index } => {
103-
writeln!(writer, "{INDENT}discriminant({place:?} = {};", variant_index.to_index())
103+
writeln!(writer, "{INDENT}discriminant({place:?}) = {};", variant_index.to_index())
104104
}
105105
StatementKind::Deinit(place) => writeln!(writer, "Deinit({place:?};"),
106106
StatementKind::StorageLive(local) => {

0 commit comments

Comments
 (0)