about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
authorNick Cameron <ncameron@mozilla.com>2014-04-03 13:53:57 +1300
committerNick Cameron <ncameron@mozilla.com>2014-04-23 12:30:58 +1200
commitc3b2f2b0c6f074fb98add56a1977d407e294c9ed (patch)
tree7eb3393df546f2c5b95d97dd3fc4c3cc73984783 /src/libsyntax/parse
parent09bfb92fdc3ccff42dfcf91b0af368f88dc3e446 (diff)
downloadrust-c3b2f2b0c6f074fb98add56a1977d407e294c9ed.tar.gz
rust-c3b2f2b0c6f074fb98add56a1977d407e294c9ed.zip
Add a span to ast::TyParam
Diffstat (limited to 'src/libsyntax/parse')
-rw-r--r--src/libsyntax/parse/parser.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index 6485b5a3622..85480bebc90 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -3393,6 +3393,7 @@ impl<'a> Parser<'a> {
     // matches typaram = IDENT optbounds ( EQ ty )?
     fn parse_ty_param(&mut self) -> TyParam {
         let ident = self.parse_ident();
+        let span = self.span;
         let (_, opt_bounds) = self.parse_optional_ty_param_bounds(false);
         // For typarams we don't care about the difference b/w "<T>" and "<T:>".
         let bounds = opt_bounds.unwrap_or_default();
@@ -3407,7 +3408,8 @@ impl<'a> Parser<'a> {
             ident: ident,
             id: ast::DUMMY_NODE_ID,
             bounds: bounds,
-            default: default
+            default: default,
+            span: span,
         }
     }