mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-13 13:48:50 +00:00
Add test for fn pointers
This commit is contained in:
parent
371c5aec1c
commit
393b7119bd
1 changed files with 15 additions and 0 deletions
|
@ -720,4 +720,19 @@ fn main() {
|
||||||
"#]],
|
"#]],
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn call_info_for_fn_ptr() {
|
||||||
|
check(
|
||||||
|
r#"
|
||||||
|
fn main(f: fn(i32, f64) -> char) {
|
||||||
|
f(0, <|>)
|
||||||
|
}
|
||||||
|
"#,
|
||||||
|
expect![[r#"
|
||||||
|
(i32, f64) -> char
|
||||||
|
(i32, <f64>)
|
||||||
|
"#]],
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue