summary refs log tree commit diff
path: root/src/libsyntax/parse/attr.rs
diff options
context:
space:
mode:
authorJorge Aparicio <japaricious@gmail.com>2015-01-07 11:58:31 -0500
committerJorge Aparicio <japaricious@gmail.com>2015-01-07 17:35:56 -0500
commit517f1cc63c1a5df148fdeef56791f66771d3d8e8 (patch)
tree0d321b5be3d9610f460561e8dc446a2132bb5422 /src/libsyntax/parse/attr.rs
parent6e2bfe4ae8277f0cfe76831b446d50820b4527f5 (diff)
downloadrust-517f1cc63c1a5df148fdeef56791f66771d3d8e8.tar.gz
rust-517f1cc63c1a5df148fdeef56791f66771d3d8e8.zip
use slicing sugar
Diffstat (limited to 'src/libsyntax/parse/attr.rs')
-rw-r--r--src/libsyntax/parse/attr.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/parse/attr.rs b/src/libsyntax/parse/attr.rs
index 4aad7f911db..54ec9c7b146 100644
--- a/src/libsyntax/parse/attr.rs
+++ b/src/libsyntax/parse/attr.rs
@@ -92,7 +92,7 @@ impl<'a> ParserAttr for Parser<'a> {
             }
             _ => {
                 let token_str = self.this_token_to_string();
-                self.fatal(format!("expected `#`, found `{}`", token_str).index(&FullRange));
+                self.fatal(&format!("expected `#`, found `{}`", token_str)[]);
             }
         };