summary refs log tree commit diff
path: root/tests/ui/traits/overflow-computing-ambiguity.rs
blob: 88eeca56cdd1ae8717f2f148c6ec86b58194c4b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#![feature(rustc_attrs)]
#![rustc_no_implicit_bounds]

trait Hello {}

struct Foo<'a, T>(&'a T);

impl<'a, T> Hello for Foo<'a, &'a T> where Foo<'a, T>: Hello {}

impl Hello for Foo<'static, i32> {}

fn hello<T: Hello>() {}

fn main() {
    hello();
    //~^ ERROR type annotations needed
}