diff options
| author | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2024-04-28 17:48:02 +0000 |
|---|---|---|
| committer | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2024-04-28 17:56:08 +0000 |
| commit | 1e485f1bd482c7b742e2f8f07fa997f1867ad609 (patch) | |
| tree | 9c739d4c87bd148e10c71af8bc90767878222ec1 /src | |
| parent | a07fd93698ad79c43b8191a164d6c666755a126b (diff) | |
| download | rust-1e485f1bd482c7b742e2f8f07fa997f1867ad609.tar.gz rust-1e485f1bd482c7b742e2f8f07fa997f1867ad609.zip | |
Fix rustc tests
Diffstat (limited to 'src')
| -rw-r--r-- | src/abi/mod.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/abi/mod.rs b/src/abi/mod.rs index 6f346af25c6..4bcef15ad04 100644 --- a/src/abi/mod.rs +++ b/src/abi/mod.rs @@ -412,7 +412,7 @@ pub(crate) fn codegen_terminator_call<'tcx>( Err(instance) => Some(instance), } } - InstanceDef::DropGlue(_, None) => { + InstanceDef::DropGlue(_, None) | ty::InstanceDef::AsyncDropGlueCtorShim(_, None) => { // empty drop glue - a nop. let dest = target.expect("Non terminating drop_in_place_real???"); let ret_block = fx.get_block(dest); @@ -597,7 +597,9 @@ pub(crate) fn codegen_drop<'tcx>( let ty = drop_place.layout().ty; let drop_instance = Instance::resolve_drop_in_place(fx.tcx, ty).polymorphize(fx.tcx); - if let ty::InstanceDef::DropGlue(_, None) = drop_instance.def { + if let ty::InstanceDef::DropGlue(_, None) | ty::InstanceDef::AsyncDropGlueCtorShim(_, None) = + drop_instance.def + { // we don't actually need to drop anything } else { match ty.kind() { |
