summaryrefslogtreecommitdiff
path: root/compiler/rustc_codegen_cranelift
diff options
context:
space:
mode:
authorGiacomo Pasini <giacomo@status.im>2023-03-05 21:02:14 +0100
committerGiacomo Pasini <giacomo@status.im>2023-03-07 14:25:22 +0100
commitc5d4e4d907047580f028c6ca7b36a82ef94d28d1 (patch)
tree5e86d4fcf511875c88ce5e828e72386387c53efd /compiler/rustc_codegen_cranelift
parent14c54b637b18f74680d0c0441216714b5e9c150d (diff)
downloadrust-c5d4e4d907047580f028c6ca7b36a82ef94d28d1.tar.gz
Remove DropAndReplace terminator
PR 107844 made DropAndReplace unused, let's remove it completely from the codebase.
Diffstat (limited to 'compiler/rustc_codegen_cranelift')
-rw-r--r--compiler/rustc_codegen_cranelift/src/base.rs1
-rw-r--r--compiler/rustc_codegen_cranelift/src/constant.rs3
2 files changed, 1 insertions, 3 deletions
diff --git a/compiler/rustc_codegen_cranelift/src/base.rs b/compiler/rustc_codegen_cranelift/src/base.rs
index 7f857528c7c..cb0e272ceda 100644
--- a/compiler/rustc_codegen_cranelift/src/base.rs
+++ b/compiler/rustc_codegen_cranelift/src/base.rs
@@ -499,7 +499,6 @@ fn codegen_fn_body(fx: &mut FunctionCx<'_, '_, '_>, start_block: Block) {
TerminatorKind::Yield { .. }
| TerminatorKind::FalseEdge { .. }
| TerminatorKind::FalseUnwind { .. }
- | TerminatorKind::DropAndReplace { .. }
| TerminatorKind::GeneratorDrop => {
bug!("shouldn't exist at codegen {:?}", bb_data.terminator());
}
diff --git a/compiler/rustc_codegen_cranelift/src/constant.rs b/compiler/rustc_codegen_cranelift/src/constant.rs
index 49c4f1aaaef..1930db72ead 100644
--- a/compiler/rustc_codegen_cranelift/src/constant.rs
+++ b/compiler/rustc_codegen_cranelift/src/constant.rs
@@ -543,8 +543,7 @@ pub(crate) fn mir_operand_get_const_val<'tcx>(
| TerminatorKind::Unreachable
| TerminatorKind::Drop { .. }
| TerminatorKind::Assert { .. } => {}
- TerminatorKind::DropAndReplace { .. }
- | TerminatorKind::Yield { .. }
+ TerminatorKind::Yield { .. }
| TerminatorKind::GeneratorDrop
| TerminatorKind::FalseEdge { .. }
| TerminatorKind::FalseUnwind { .. } => unreachable!(),