]> git.proxmox.com Git - rustc.git/blob - tests/ui/foreign/issue-74120-lowering-of-ffi-block-bodies.stderr
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / foreign / issue-74120-lowering-of-ffi-block-bodies.stderr
1 error: incorrect function inside `extern` block
2 --> $DIR/issue-74120-lowering-of-ffi-block-bodies.rs:7:8
3 |
4 LL | extern "C" {
5 | ---------- `extern` blocks define existing foreign functions and functions inside of them cannot have a body
6 LL | fn f() {
7 | ________^___-
8 | | |
9 | | cannot have a body
10 LL | |
11 LL | | fn g() {}
12 LL | | }
13 | |_____- help: remove the invalid body: `;`
14 |
15 = help: you might have meant to write a function accessible through FFI, which can be done by writing `extern fn` outside of the `extern` block
16 = note: for more information, visit https://doc.rust-lang.org/std/keyword.extern.html
17
18 error: aborting due to previous error
19