about summary refs log tree commit diff
path: root/tests/ui/traits/issue-2611-3.rs
blob: c95ebae33fa9b82de26ecc7f53caffc5754da00d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
//@ check-pass
#![allow(dead_code)]
// Tests that impls are allowed to have looser, more permissive bounds
// than the traits require.


trait A {
  fn b<C:Sync,D>(&self, x: C) -> C;
}

struct E {
 f: isize
}

impl A for E {
  fn b<F,G>(&self, _x: F) -> F { panic!() }
}

pub fn main() {}