// Repro for . //@ edition: 2021 //@ revisions: assumptions no_assumptions //@[assumptions] compile-flags: -Zhigher-ranked-assumptions //@[assumptions] check-pass //@[no_assumptions] known-bug: #110338 use std::future::Future; trait BoringTrait {} trait TraitWithAssocType { type Assoc; } impl TraitWithAssocType<()> for T where T: ?Sized + 'static, { type Assoc = (); } fn evil_function + ?Sized, I>() -> impl Future> { async { Ok(()) } } fn fails_to_compile() -> impl std::future::Future + Send { async { let _ = evil_function::().await; } } fn main() {}