diff options
| author | Nicholas Nethercote <nnethercote@mozilla.com> | 2020-07-08 11:04:10 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <nnethercote@mozilla.com> | 2020-07-15 08:42:59 +1000 |
| commit | f04e866e5752f47e0896550faf40e19fea22d8ea (patch) | |
| tree | dc192030f27fb19c6c842775f931f6a7494a0020 /src/librustc_driver | |
| parent | e284f5d050029906d32667635af9c839fafd3eca (diff) | |
Add and use more static symbols.
Note that the output of `unpretty-debug.stdout` has changed. In that test the hash values are normalized from a symbol numbers to small numbers like "0#0" and "0#1". The increase in the number of static symbols must have caused the original numbers to contain more digits, resulting in different pretty-printing prior to normalization.
Diffstat (limited to 'src/librustc_driver')
| -rw-r--r-- | src/librustc_driver/lib.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/librustc_driver/lib.rs b/src/librustc_driver/lib.rs index c2c19b6b405..be11e29cb25 100644 --- a/src/librustc_driver/lib.rs +++ b/src/librustc_driver/lib.rs @@ -698,7 +698,7 @@ impl RustcDefaultCalls { .parse_sess .config .iter() - .filter_map(|&(name, ref value)| { + .filter_map(|&(name, value)| { // Note that crt-static is a specially recognized cfg // directive that's printed out here as part of // rust-lang/rust#37406, but in general the @@ -707,9 +707,7 @@ impl RustcDefaultCalls { // specifically allowing the crt-static cfg and that's // it, this is intended to get into Cargo and then go // through to build scripts. - let value = value.as_ref().map(|s| s.as_str()); - let value = value.as_ref().map(|s| s.as_ref()); - if (name != sym::target_feature || value != Some("crt-static")) + if (name != sym::target_feature || value != Some(sym::crt_dash_static)) && !allow_unstable_cfg && find_gated_cfg(|cfg_sym| cfg_sym == name).is_some() { |
