-
Notifications
You must be signed in to change notification settings - Fork 12.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Get rid of infer vars in inherent assoc types selection by using probe
- Loading branch information
1 parent
4b26bb5
commit 6312382
Showing
3 changed files
with
35 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
tests/ui/associated-inherent-types/assoc-inherent-late-bound.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// check-pass | ||
|
||
#![feature(inherent_associated_types)] | ||
#![allow(incomplete_features)] | ||
|
||
struct Foo<T>(T); | ||
|
||
impl<'a> Foo<fn(&'a ())> { | ||
type Assoc = &'a (); | ||
} | ||
|
||
fn bar(_: for<'a> fn(Foo<fn(Foo<fn(&'static ())>::Assoc)>::Assoc)) {} | ||
|
||
fn main() {} |