Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/ide-diagnostics/src/handlers/missing_unsafe.rs')
| -rw-r--r-- | crates/ide-diagnostics/src/handlers/missing_unsafe.rs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/crates/ide-diagnostics/src/handlers/missing_unsafe.rs b/crates/ide-diagnostics/src/handlers/missing_unsafe.rs index df1cd76cf7..1abb50144d 100644 --- a/crates/ide-diagnostics/src/handlers/missing_unsafe.rs +++ b/crates/ide-diagnostics/src/handlers/missing_unsafe.rs @@ -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(); } "#, ); @@ -1094,4 +1098,19 @@ fn main() { "#, ); } + + #[test] + fn multiple_target_feature_enable() { + check_diagnostics( + r#" +#[target_feature(enable = "avx2,fma")] +fn foo() {} + +#[target_feature(enable = "avx2", enable = "fma")] +fn bar() { + foo(); +} + "#, + ); + } } |