summaryrefslogtreecommitdiffstats
path: root/src/test/ui/unboxed-closures/unboxed-closures-type-mismatch.rs
blob: 9f76849e5fbffddafc646570d50e76222edb3b17 (plain)
1
2
3
4
5
6
7
use std::ops::FnMut;

pub fn main() {
    let mut f = |x: isize, y: isize| -> isize { x + y };
    let z = f(1_usize, 2);    //~ ERROR mismatched types
    println!("{}", z);
}