]> git.lizzy.rs Git - rust.git/blob - src/test/ui/fn/signature-error-reporting-under-verbose.rs
Auto merge of #105160 - nnethercote:rm-Lit-token_lit, r=petrochenkov
[rust.git] / src / test / ui / fn / signature-error-reporting-under-verbose.rs
1 // compile-flags: -Zverbose
2
3 fn foo(_: i32, _: i32) {}
4
5 fn needs_ptr(_: fn(i32, u32)) {}
6 //~^ NOTE function defined here
7 //~| NOTE
8
9 fn main() {
10     needs_ptr(foo);
11     //~^ ERROR mismatched types
12     //~| NOTE expected `u32`, found `i32`
13     //~| NOTE expected fn pointer `fn(i32, u32)`
14     //~| NOTE arguments to this function are incorrect
15 }