-
Notifications
You must be signed in to change notification settings - Fork 13.7k
Open
Labels
A-resolveArea: Name/path resolution done by `rustc_resolve` specificallyArea: Name/path resolution done by `rustc_resolve` specificallyC-bugCategory: This is a bug.Category: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Description
We should emit the same error message here regardless of whether the projection type contains bound regions.
fn test<'x>() {
use std::ops::Deref;
None::<for<'y> fn(<&'x Option<()> as Deref>::Target::Some)>;
//~^ ERROR expected type, found variant
None::<for<'y> fn(<&'y Option<()> as Deref>::Target::Some)>;
//~^ ERROR ambiguous associated type
}
I discovered this in #101947 and added a FIXME comment.
@rustbot label T-compiler C-bug A-resolve
Metadata
Metadata
Assignees
Labels
A-resolveArea: Name/path resolution done by `rustc_resolve` specificallyArea: Name/path resolution done by `rustc_resolve` specificallyC-bugCategory: This is a bug.Category: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.