rust/tests/ui/parser/no-const-fn-in-extern-block.stderr
2023-01-11 09:32:08 +00:00

30 lines
630 B
Plaintext

error: functions in `extern` blocks cannot have qualifiers
--> $DIR/no-const-fn-in-extern-block.rs:2:14
|
LL | extern "C" {
| ---------- in this `extern` block
LL | const fn foo();
| ^^^
|
help: remove the qualifiers
|
LL | fn foo();
| ~~
error: functions in `extern` blocks cannot have qualifiers
--> $DIR/no-const-fn-in-extern-block.rs:4:21
|
LL | extern "C" {
| ---------- in this `extern` block
...
LL | const unsafe fn bar();
| ^^^
|
help: remove the qualifiers
|
LL | fn bar();
| ~~
error: aborting due to 2 previous errors