diff options
| author | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2023-09-27 11:20:17 +0000 |
|---|---|---|
| committer | Oli Scherer <git-spam-no-reply9815368754983@oli-obk.de> | 2023-09-28 16:13:38 +0000 |
| commit | 6ea2db7c2d78182fabf66a8c6ffc856446e1cf81 (patch) | |
| tree | b3f085e5d90b8de6cdfa4eb14a7b1f64c4ee13ad /compiler/rustc_codegen_ssa/src | |
| parent | 479fa4a74d74b69c9bc5fc330519a92590f170e4 (diff) | |
| download | rust-6ea2db7c2d78182fabf66a8c6ffc856446e1cf81.tar.gz rust-6ea2db7c2d78182fabf66a8c6ffc856446e1cf81.zip | |
Strip `OpaqueCast` during `RevealAll`.
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/mir/place.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/mir/place.rs b/compiler/rustc_codegen_ssa/src/mir/place.rs index a9ecbdc5f35..f775711f870 100644 --- a/compiler/rustc_codegen_ssa/src/mir/place.rs +++ b/compiler/rustc_codegen_ssa/src/mir/place.rs @@ -463,7 +463,9 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> { mir::ProjectionElem::Field(ref field, _) => { cg_base.project_field(bx, field.index()) } - mir::ProjectionElem::OpaqueCast(ty) => cg_base.project_type(bx, ty), + mir::ProjectionElem::OpaqueCast(ty) => { + bug!("encountered OpaqueCast({ty}) in codegen") + } mir::ProjectionElem::Index(index) => { let index = &mir::Operand::Copy(mir::Place::from(index)); let index = self.codegen_operand(bx, index); |
