1 // build-pass (FIXME(62277): could be check-pass?)
3 fn with_closure<F, A>(_: F)
4 where F: FnOnce(A, &u32)
9 // This version works; we infer `A` to be `u32`, and take the type
10 // of `y` to be `&u32`.
11 with_closure(|x: u32, y| {});
14 fn bar<'x>(x: &'x u32) {
16 with_closure(|x: &'x u32, y| {});