diff options
| author | John Kåre Alsaker <john.kare.alsaker@gmail.com> | 2024-03-12 02:12:28 +0100 |
|---|---|---|
| committer | John Kåre Alsaker <john.kare.alsaker@gmail.com> | 2024-08-11 04:16:53 +0200 |
| commit | 3ee43259ac9ddb7d5e050e9c7e65c848550045da (patch) | |
| tree | 7941360eb937918b73747169021f2450aa742782 /src/tools | |
| parent | 730d5d4095a264ef5f7c0a0781eea68c15431d45 (diff) | |
Link `std` statically in `rustc_driver`
Diffstat (limited to 'src/tools')
| -rw-r--r-- | src/tools/clippy/src/main.rs | 3 | ||||
| -rw-r--r-- | src/tools/clippy/tests/compile-test.rs | 3 | ||||
| -rw-r--r-- | src/tools/rustdoc/main.rs | 3 | ||||
| -rw-r--r-- | src/tools/rustfmt/src/git-rustfmt/main.rs | 4 |
4 files changed, 13 insertions, 0 deletions
diff --git a/src/tools/clippy/src/main.rs b/src/tools/clippy/src/main.rs index c9af2138a72..c9853e53f3b 100644 --- a/src/tools/clippy/src/main.rs +++ b/src/tools/clippy/src/main.rs @@ -1,3 +1,6 @@ +// We need this feature as it changes `dylib` linking behavior and allows us to link to +// `rustc_driver`. +#![feature(rustc_private)] // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] diff --git a/src/tools/clippy/tests/compile-test.rs b/src/tools/clippy/tests/compile-test.rs index c7080e5dcdc..64253514fbe 100644 --- a/src/tools/clippy/tests/compile-test.rs +++ b/src/tools/clippy/tests/compile-test.rs @@ -1,3 +1,6 @@ +// We need this feature as it changes `dylib` linking behavior and allows us to link to +// `rustc_driver`. +#![feature(rustc_private)] #![warn(rust_2018_idioms, unused_lifetimes)] #![allow(unused_extern_crates)] diff --git a/src/tools/rustdoc/main.rs b/src/tools/rustdoc/main.rs index 5b499a1fa1f..d4099cafe5d 100644 --- a/src/tools/rustdoc/main.rs +++ b/src/tools/rustdoc/main.rs @@ -1,3 +1,6 @@ +// We need this feature as it changes `dylib` linking behavior and allows us to link to `rustc_driver`. +#![feature(rustc_private)] + fn main() { rustdoc::main() } diff --git a/src/tools/rustfmt/src/git-rustfmt/main.rs b/src/tools/rustfmt/src/git-rustfmt/main.rs index 3059d917c6b..5674f40bef9 100644 --- a/src/tools/rustfmt/src/git-rustfmt/main.rs +++ b/src/tools/rustfmt/src/git-rustfmt/main.rs @@ -1,3 +1,7 @@ +// We need this feature as it changes `dylib` linking behavior and allows us to link to +// `rustc_driver`. +#![feature(rustc_private)] + #[macro_use] extern crate tracing; |
