We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent df33e02 commit a10d157Copy full SHA for a10d157
compiler/rustc_mir_transform/src/unreachable_enum_branching.rs
@@ -177,7 +177,7 @@ impl<'tcx> MirPass<'tcx> for UnreachableEnumBranching {
177
&& allowed_variants.len() == 1
178
&& check_successors(&body.basic_blocks, targets.otherwise());
179
let replace_otherwise_to_unreachable = otherwise_is_last_variant
180
- || !otherwise_is_empty_unreachable && allowed_variants.is_empty();
+ || (!otherwise_is_empty_unreachable && allowed_variants.is_empty());
181
182
if unreachable_targets.is_empty() && !replace_otherwise_to_unreachable {
183
continue;
0 commit comments