diff options
| author | est31 <MTest31@outlook.com> | 2020-10-14 18:42:13 +0200 |
|---|---|---|
| committer | est31 <MTest31@outlook.com> | 2020-10-15 12:02:24 +0200 |
| commit | d683e3ac23a8f8b52cef07b4380845bbd1ef5e8f (patch) | |
| tree | e29bfbbf1e7538cc22ada967111fa542e73c05a9 /compiler/rustc_codegen_ssa/src | |
| parent | 4fa55787745ac71793253c47c4d6cd5ffe96b741 (diff) | |
| download | rust-d683e3ac23a8f8b52cef07b4380845bbd1ef5e8f.tar.gz rust-d683e3ac23a8f8b52cef07b4380845bbd1ef5e8f.zip | |
Remove rustc_session::config::Config
The wrapper type led to tons of target.target across the compiler. Its ptr_width field isn't required any more, as target_pointer_width is already present in parsed form.
Diffstat (limited to 'compiler/rustc_codegen_ssa/src')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/link.rs | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/link.rs b/compiler/rustc_codegen_ssa/src/back/link.rs index e3b4b6866cf..63d0a88858e 100644 --- a/compiler/rustc_codegen_ssa/src/back/link.rs +++ b/compiler/rustc_codegen_ssa/src/back/link.rs @@ -15,7 +15,7 @@ use rustc_session::{filesearch, Session}; use rustc_span::symbol::Symbol; use rustc_target::spec::crt_objects::{CrtObjects, CrtObjectsFallback}; use rustc_target::spec::{LinkOutputKind, LinkerFlavor, LldFlavor}; -use rustc_target::spec::{PanicStrategy, RelocModel, RelroLevel}; +use rustc_target::spec::{PanicStrategy, RelocModel, RelroLevel, Target}; use super::archive::ArchiveBuilder; use super::command::Command; @@ -1842,12 +1842,8 @@ fn add_upstream_rust_crates<'a, B: ArchiveBuilder<'a>>( } // Converts a library file-stem into a cc -l argument - fn unlib<'a>(config: &config::Config, stem: &'a str) -> &'a str { - if stem.starts_with("lib") && !config.target.options.is_like_windows { - &stem[3..] - } else { - stem - } + fn unlib<'a>(target: &Target, stem: &'a str) -> &'a str { + if stem.starts_with("lib") && !target.options.is_like_windows { &stem[3..] } else { stem } } // Adds the static "rlib" versions of all crates to the command line. |
