Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Remove warning about arbitrarily set CLI cfgs
Now that explicit_builtin_cfgs_in_flags is deny-by-default, I don't
think we need this warning anymore.
  • Loading branch information
ehuss committed Mar 6, 2025
commit 8319abcc7e35a4c529ec118d0da65c6e65345ec4
5 changes: 0 additions & 5 deletions src/conditional-compilation.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,6 @@ configuration option from within the source code of the crate being compiled.
> by [Cargo][cargo-feature] for specifying compile-time options and optional
> dependencies.

> [!WARNING]
> Arbitrarily-set configuration options can clash with compiler-set configuration options. For example, it is possible to do `rustc --cfg "unix" program.rs` while compiling to a Windows target, and have both `unix` and `windows` configuration options set at the same time. Doing this would be unwise.
>
> Since Rust 1.82 `rustc` prevents setting configuration options that can clash with it's set of builtin configurations with the deny-by-default [`explicit_builtin_cfgs_in_flags`](https://doc.rust-lang.org/rustc/lints/listing/deny-by-default.html#explicit-builtin-cfgs-in-flags) lint.

r[cfg.target_arch]
### `target_arch`

Expand Down