diff options
Diffstat (limited to 'src/test/ui/associated-types/associated-types-binding-in-where-clause.rs')
-rw-r--r-- | src/test/ui/associated-types/associated-types-binding-in-where-clause.rs | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/src/test/ui/associated-types/associated-types-binding-in-where-clause.rs b/src/test/ui/associated-types/associated-types-binding-in-where-clause.rs deleted file mode 100644 index c54bc3cd6..000000000 --- a/src/test/ui/associated-types/associated-types-binding-in-where-clause.rs +++ /dev/null @@ -1,38 +0,0 @@ -// run-pass -// Test equality constraints on associated types in a where clause. - -// pretty-expanded FIXME #23616 - -pub trait Foo { - type A; - fn boo(&self) -> <Self as Foo>::A; -} - -#[derive(PartialEq)] -pub struct Bar; - -impl Foo for isize { - type A = usize; - fn boo(&self) -> usize { 42 } -} - -impl Foo for char { - type A = Bar; - fn boo(&self) -> Bar { Bar } -} - -fn foo_bar<I: Foo<A=Bar>>(x: I) -> Bar { - x.boo() -} - -fn foo_uint<I: Foo<A=usize>>(x: I) -> usize { - x.boo() -} - -pub fn main() { - let a = 42; - foo_uint(a); - - let a = 'a'; - foo_bar(a); -} |