Skip to content

Commit

Permalink
Reorder test lint settings to ignore unknown rust-2024-compatibility …
Browse files Browse the repository at this point in the history
…in old rustc

The `allow(unknown_lints)` applies only to attributes that come after it.

    warning: unknown lint: `rust_2024_compatibility`
     --> tests/distributed_slice.rs:2:9
      |
    2 | #![deny(rust_2024_compatibility, unsafe_op_in_unsafe_fn)]
      |         ^^^^^^^^^^^^^^^^^^^^^^^ help: did you mean: `rust_2021_compatibility`
      |
      = note: `#[warn(unknown_lints)]` on by default
  • Loading branch information
dtolnay committed Nov 11, 2024
1 parent 42a27d9 commit 107cd3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/distributed_slice.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#![cfg_attr(feature = "used_linker", feature(used_with_arg))]
#![deny(rust_2024_compatibility, unsafe_op_in_unsafe_fn)]
#![allow(unknown_lints, non_local_definitions)] // FIXME
#![deny(rust_2024_compatibility, unsafe_op_in_unsafe_fn)]

use linkme::distributed_slice;
use once_cell::sync::Lazy;
Expand Down

0 comments on commit 107cd3c

Please sign in to comment.