]> git.lizzy.rs Git - rust.git/blob - src/test/ui/in-band-lifetimes/E0687.rs
Do not suggest using a const parameter when there are bounds on an unused type parameter
[rust.git] / src / test / ui / in-band-lifetimes / E0687.rs
1 #![allow(warnings)]
2 #![feature(in_band_lifetimes)]
3
4 fn foo(x: fn(&'a u32)) {} //~ ERROR must be explicitly
5
6 fn bar(x: &Fn(&'a u32)) {} //~ ERROR must be explicitly
7
8 fn baz(x: fn(&'a u32), y: &'a u32) {} //~ ERROR must be explicitly
9
10 struct Foo<'a> { x: &'a u32 }
11
12 impl Foo<'a> {
13     fn bar(&self, x: fn(&'a u32)) {} //~ ERROR must be explicitly
14 }
15
16 fn main() {}