about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
authorDavid Wood <david@davidtw.co>2018-09-17 19:39:37 +0200
committerDavid Wood <david@davidtw.co>2018-09-23 14:18:34 +0200
commit3becbbc1299f6938ff13f09ee3b3f37f7600326f (patch)
tree5c118a9775eb1650114df7bfafed98a0fc0e33d0 /src/libsyntax/parse
parent97bbcabef15309ba9ab9bc9d365d4524ce26fc09 (diff)
downloadrust-3becbbc1299f6938ff13f09ee3b3f37f7600326f.tar.gz
rust-3becbbc1299f6938ff13f09ee3b3f37f7600326f.zip
Fixed off-by-one span.
Fixes the off-by-one span issue where closure argument spans were
pointing to the token after the argument.
Diffstat (limited to 'src/libsyntax/parse')
-rw-r--r--src/libsyntax/parse/parser.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 7a13beb7852..d6cbe47a66e 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -1848,7 +1848,7 @@ impl<'a> Parser<'a> {
             P(Ty {
                 id: ast::DUMMY_NODE_ID,
                 node: TyKind::Infer,
-                span: self.span,
+                span: self.prev_span,
             })
         };
         Ok(Arg {