diff options
| author | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-05-08 13:21:18 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-05-13 09:29:22 +1000 |
| commit | fb084a48e2ca663de41b316dc6ece2dceb93e24e (patch) | |
| tree | b78379f996dceee6039ea4880c66e7fe30b3efad /src/librustc_codegen_utils/link.rs | |
| parent | 79602c87b561e26fa1a8fe58b9130cca37375f90 (diff) | |
| download | rust-fb084a48e2ca663de41b316dc6ece2dceb93e24e.tar.gz rust-fb084a48e2ca663de41b316dc6ece2dceb93e24e.zip | |
Pass a `Symbol` to `check_name`, `emit_feature_err`, and related functions.
Diffstat (limited to 'src/librustc_codegen_utils/link.rs')
| -rw-r--r-- | src/librustc_codegen_utils/link.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/librustc_codegen_utils/link.rs b/src/librustc_codegen_utils/link.rs index f3a1b219f8a..30f37fefa7c 100644 --- a/src/librustc_codegen_utils/link.rs +++ b/src/librustc_codegen_utils/link.rs @@ -2,6 +2,7 @@ use rustc::session::config::{self, OutputFilenames, Input, OutputType}; use rustc::session::Session; use std::path::{Path, PathBuf}; use syntax::{ast, attr}; +use syntax::symbol::sym; use syntax_pos::Span; pub fn out_filename(sess: &Session, @@ -49,7 +50,7 @@ pub fn find_crate_name(sess: Option<&Session>, // as used. After doing this, however, we still prioritize a crate name from // the command line over one found in the #[crate_name] attribute. If we // find both we ensure that they're the same later on as well. - let attr_crate_name = attr::find_by_name(attrs, "crate_name") + let attr_crate_name = attr::find_by_name(attrs, sym::crate_name) .and_then(|at| at.value_str().map(|s| (at, s))); if let Some(sess) = sess { |
