about summary refs log tree commit diff
path: root/compiler/rustc_middle/src/ty/instance.rs
diff options
context:
space:
mode:
authorMatthias Krüger <476013+matthiaskrgr@users.noreply.github.com>2025-03-19 08:17:18 +0100
committerGitHub <noreply@github.com>2025-03-19 08:17:18 +0100
commit351ba39d54daddaaa0edcfe9665bfddc0d7ac693 (patch)
tree13f609090e88925dc1b51a83220de6f7213d89a9 /compiler/rustc_middle/src/ty/instance.rs
parent8b713e2cdede4b50135948f0b4f15971103b3edc (diff)
parent93b31d9b21f5a7066cba65ecbf85f2ef16dec891 (diff)
Rollup merge of #138670 - compiler-errors:remove-afidt, r=oli-obk
Remove existing AFIDT implementation

This experiment will need to be reworked differently; I don't think we'll be going with the `dyn* Future` approach that is currently implemented.

r? oli-obk

Fixes #136286
Fixes #137706
Fixes #137895

Tracking:
* #133119
Diffstat (limited to 'compiler/rustc_middle/src/ty/instance.rs')
-rw-r--r--compiler/rustc_middle/src/ty/instance.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/compiler/rustc_middle/src/ty/instance.rs b/compiler/rustc_middle/src/ty/instance.rs
index b99148f3368..980d20f9d3b 100644
--- a/compiler/rustc_middle/src/ty/instance.rs
+++ b/compiler/rustc_middle/src/ty/instance.rs
@@ -712,10 +712,7 @@ impl<'tcx> Instance<'tcx> {
                             ..
                         })
                     );
-                // We also need to generate a shim if this is an AFIT.
-                let needs_rpitit_shim =
-                    tcx.return_position_impl_trait_in_trait_shim_data(def).is_some();
-                if needs_track_caller_shim || needs_rpitit_shim {
+                if needs_track_caller_shim {
                     if tcx.is_closure_like(def) {
                         debug!(
                             " => vtable fn pointer created for closure with #[track_caller]: {:?} for method {:?} {:?}",