]>
git.proxmox.com Git - rustc.git/blob - tests/ui/functions-closures/closure-inference.rs
2 #![allow(unused_braces)]
4 fn foo(i
: isize) -> isize { i + 1 }
6 fn apply
<A
, F
>(f
: F
, v
: A
) -> A
where F
: FnOnce(A
) -> A { f(v) }
10 assert_eq
!(apply(f
, 2), 3);