You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
scottmcm opened this issue
May 25, 2023
· 2 comments
· Fixed by #112260
Assignees
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
But it actually catches more than that, for example
error: declaration of a `no_mangle` function
--> src/lib.rs:3:1
|
3 | #[no_mangle]
| ^^^^^^^^^^^^
|
= note: the linker's behavior with multiple libraries exporting duplicate symbol names is undefined and Rust cannot provide guarantees when you manually override them
note: the lint level is defined here
--> src/lib.rs:1:11
|
1 | #![forbid(unsafe_code)]
| ^^^^^^^^^^^
It would be nice for the documentation to include examples of those other things that the lint catches because they might result in unsoundness despite the unsafe token not appearing in them.
The text was updated successfully, but these errors were encountered:
scottmcm
added
the
E-easy
Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
label
May 25, 2023
clubby789
added
the
A-docs
Area: Documentation for any part of the project, including the compiler, standard library, and tools
label
May 25, 2023
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsE-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Today, the
unsafe_code
lint documentation https://doc.rust-lang.org/nightly/rustc/lints/listing/allowed-by-default.html#unsafe-code only mentions that it catchesunsafe
blocks.But it actually catches more than that, for example
It would be nice for the documentation to include examples of those other things that the lint catches because they might result in unsoundness despite the
unsafe
token not appearing in them.The text was updated successfully, but these errors were encountered: