Change:
<!-- Thank you for filing a bug report! Please provide a short summary of the bug, along with any information you feel relevant to replicating the bug. --Within an , a GAT bound of does not compile, asking me to add an explicit bound. This code results in two errors: I believe that the error is a bug, as since is known in this to be , must outlive and the suggested bound should thus already be implied by . Applying the suggested fix removes this error, but obviously cannot compile (as the GAT impl now has a stricter than in the declaration). The first error seems incorrect too, as there is no visible difference between the highlighted lines other than : Adding the type bound on the declaration avoids these errors, but is less generic. <!-- If you're using the stable version of the compiler, you should also check if the bug also exists in the beta or nightly versions. --: I have also encountered this bug on . </details
label +F-genericassociatedtypes +T-compiler
It's both rude and unconstructive to suggest that issues are not tracked. First and foremost, this is an unstable feature. Second, this issue was filed 15 days ago, right in the middle of holidays. Third, its labeled appropriately, and I'll either triage or fix it when I can. I'm going to delete the above comment since it's not constructive at all.
I forgot what I said before, but if I said something bad, I'm really sorry for that

Discussion:
"cannot process registered region obligations in a snapshot" ); <del> debug!("process_registered_region_obligations()"); </del> <ins> debug!(?param_env, "process_registered_region_obligations()"); </ins> let my_region_obligations = self.take_registered_region_obligations();

let trait_bounds: Vec<_> = self.verify_bound.projection_declared_bounds_from_trait(projection_ty).collect(); <ins> debug!(?trait_bounds); </ins> // Compute the bounds we can derive from the environment. This // is an "approximate" match -- in some cases, these bounds // may not apply.

Component::UnresolvedInferenceVariable(_) => None, <del> Component::Projection(_) | Component::EscapingProjection(_) => { // We can probably do more here. This // corresponds to a case like `<T as // Foo<'a>>::U: 'b`. </del> <ins> Component::Projection(projection) => { // We might end up here if we have `Foo<<Bar as Baz>::Assoc>: 'a`. // With this, we can deduce that `<Bar as Baz>::Assoc: 'a`. let ty = tcx.mk_projection(projection.item_def_id, projection.substs); Some(ty::PredicateKind::TypeOutlives(ty::OutlivesPredicate( ty, r_min, ))) } Component::EscapingProjection(_) => { // We might be able to do more here, but we don't // want to deal with escaping vars right now. </ins> None } })

})?); if let ty::Projection(..) = placeholder_self_ty.kind() { <del> for predicate in tcx.predicates_of(def_id).instantiate_own(tcx, substs).predicates { </del> <ins> let predicates = tcx.predicates_of(def_id).instantiate_own(tcx, substs).predicates; debug!(?predicates, "projection predicates"); for predicate in predicates { </ins> let normalized = normalize_with_depth_to( self, obligation.param_env,

<ins> error[E0311]: the parameter type `C` may not live long enough --> $DIR/issue-92096.rs:20:33 | LL | fn call_connect<C>(c: &'_ C) -> impl '_ + Future + Send |                 -               ^^^^^^^^^^^^^^^^^^^^^^^ ...so that the type `C` will meet its required lifetime bounds |                 | |                 help: consider adding an explicit lifetime bound...: `C: 'a` error[E0311]: the parameter type `C` may not live long enough --> $DIR/issue-92096.rs:20:33 | LL | fn call_connect<C>(c: &'_ C) -> impl '_ + Future + Send |                 -               ^^^^^^^^^^^^^^^^^^^^^^^ ...so that the type `C` will meet its required lifetime bounds |                 | |                 help: consider adding an explicit lifetime bound...: `C: 'a` error: aborting due to 2 previous errors </ins>

<ins> // edition:2018 // [nll] check-pass // revisions: migrate nll // Explicitly testing nll with revision, so ignore compare-mode=nll // ignore-compare-mode-nll #![cfg_attr(nll, feature(nll))] #![feature(generic_associated_types)] use std::future::Future; trait Client { type Connecting<'a>: Future + Send where Self: 'a; fn connect(&'_ self) -> Self::Connecting<'_>; } fn call_connect<C>(c: &'_ C) -> impl '_ + Future + Send //[migrate]~^ ERROR the parameter //[migrate]~| ERROR the parameter where C: Client + Send + Sync, { async move { c.connect().await } } fn main() {} </ins>

<ins> // check-pass #![feature(generic_associated_types)] #![allow(non_camel_case_types)] trait HasAssoc { type Assoc; } trait Iterate<S: HasAssoc> { type Iter<'a> where Self: 'a; } struct KeySegment_Broken<T> { key: T, } impl<S: HasAssoc> Iterate<S> for KeySegment_Broken<S::Assoc> { type Iter<'a> where Self: 'a, = (); } fn main() {} </ins>