about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
authorMikhail Modin <mikhailm1@gmail.com>2016-09-16 21:44:15 +0300
committerMikhail Modin <mikhailm1@gmail.com>2016-09-16 21:44:15 +0300
commit82639d4f0429eedd868d25d78b69a9fd96e5d200 (patch)
tree5b61516b7be0f2bf1084415259a6d76f05c88972 /src/libsyntax/parse
parent8394685b8385156fc4bc31cfbc693867e276d9d7 (diff)
downloadrust-82639d4f0429eedd868d25d78b69a9fd96e5d200.tar.gz
rust-82639d4f0429eedd868d25d78b69a9fd96e5d200.zip
fix top level attr spans
Diffstat (limited to 'src/libsyntax/parse')
-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 a0defbc09dc..9eac024edb1 100644
--- a/src/libsyntax/parse/attr.rs
+++ b/src/libsyntax/parse/attr.rs
@@ -125,8 +125,8 @@ impl<'a> Parser<'a> {
 
                 self.expect(&token::OpenDelim(token::Bracket))?;
                 let meta_item = self.parse_meta_item()?;
-                let hi = self.last_span.hi;
                 self.expect(&token::CloseDelim(token::Bracket))?;
+                let hi = self.last_span.hi;
 
                 (mk_sp(lo, hi), meta_item, style)
             }