Merge pull request #21244 from ChayimFriedman2/deprecated-safe
fix: `#[rustc_deprecated_safe_2024]` can also come as `#[rustc_deprecated_safe_2024(audit_that = "reason")]`
This commit is contained in:
commit
533fac504c
2 changed files with 7 additions and 0 deletions
|
|
@ -155,6 +155,9 @@ fn match_attr_flags(attr_flags: &mut AttrFlags, attr: Meta) -> ControlFlow<Infal
|
|||
"rustc_skip_during_method_dispatch" => {
|
||||
extract_rustc_skip_during_method_dispatch(attr_flags, tt)
|
||||
}
|
||||
"rustc_deprecated_safe_2024" => {
|
||||
attr_flags.insert(AttrFlags::RUSTC_DEPRECATED_SAFE_2024)
|
||||
}
|
||||
_ => {}
|
||||
},
|
||||
2 => match path.segments[0].text() {
|
||||
|
|
|
|||
|
|
@ -296,8 +296,12 @@ fn main() {
|
|||
#[rustc_deprecated_safe_2024]
|
||||
fn set_var() {}
|
||||
|
||||
#[rustc_deprecated_safe_2024(audit_that = "something")]
|
||||
fn set_var2() {}
|
||||
|
||||
fn main() {
|
||||
set_var();
|
||||
set_var2();
|
||||
}
|
||||
"#,
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue