Missing attribute name and corrupted output for unsafe attribute used without unsafe #134078
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
A-edition-2024
Area: The 2024 edition
A-proc-macros
Area: Procedural macros
A-suggestion-diagnostics
Area: Suggestions generated by the compiler applied by `cargo fix`
D-invalid-suggestion
Diagnostics: A structured suggestion resulting in incorrect code.
L-unsafe_attr_outside_unsafe
Lint: unsafe_attr_outside_unsafe
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
Current output
Running
cargo check
from thefoo
directory:Desired output
Rationale and extra context
Note that the problem occurs only when
bar
uses edition 2024. It doesn't matter iffoo
does too.Other cases
No response
Rust Version
Anything else?
No response
The text was updated successfully, but these errors were encountered: