about summary refs log tree commit diff
path: root/src/libsyntax/parse/parser.rs
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2017-03-27 15:24:14 -0500
committerAlex Crichton <alex@alexcrichton.com>2017-03-27 15:56:23 -0700
commit666bb1959ec072665d2e8765b01dd96127589177 (patch)
treed8a4596b9bcc6328ab30c9c0406a5b1c3bc8fe8a /src/libsyntax/parse/parser.rs
parent76cc08b45a11d0c3d8839ba458fb5685b97cd5cb (diff)
parenteb447f4ef436f0c6211a13de1e6150a09228a9c6 (diff)
Rollup merge of #40606 - oli-obk:interned_str_usability, r=jseyfried
Improve `InternedString` usability
Diffstat (limited to 'src/libsyntax/parse/parser.rs')
-rw-r--r--src/libsyntax/parse/parser.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 649e9059934..43a9d8c5f78 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -5151,15 +5151,15 @@ impl<'a> Parser<'a> {
 
     fn push_directory(&mut self, id: Ident, attrs: &[Attribute]) {
         if let Some(path) = attr::first_attr_value_str_by_name(attrs, "path") {
-            self.directory.path.push(&*path.as_str());
+            self.directory.path.push(&path.as_str());
             self.directory.ownership = DirectoryOwnership::Owned;
         } else {
-            self.directory.path.push(&*id.name.as_str());
+            self.directory.path.push(&id.name.as_str());
         }
     }
 
     pub fn submod_path_from_attr(attrs: &[ast::Attribute], dir_path: &Path) -> Option<PathBuf> {
-        attr::first_attr_value_str_by_name(attrs, "path").map(|d| dir_path.join(&*d.as_str()))
+        attr::first_attr_value_str_by_name(attrs, "path").map(|d| dir_path.join(&d.as_str()))
     }
 
     /// Returns either a path to a module, or .