forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathissue-32201.stderr
More file actions
20 lines (18 loc) · 765 Bytes
/
issue-32201.stderr
File metadata and controls
20 lines (18 loc) · 765 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
error[E0617]: can't pass `{fn item bar: fn(*const u8)}` to variadic function
--> $DIR/issue-32201.rs:9:16
|
LL | foo(0, bar);
| ^^^
|
= help: a function item is zero-sized and needs to be casted into a function pointer to be used in FFI
= note: for more information on function items, visit https://doc.rust-lang.org/reference/types/function-item.html
help: cast the value to `fn(*const u8)`
|
LL | foo(0, bar as fn(*const u8));
| ~~~~~~~~~~~~~~~~~~~~
help: cast the value into a function pointer
|
LL | foo(0, bar as fn(*const u8));
| ++++++++++++++++
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0617`.