From c3b2f2b0c6f074fb98add56a1977d407e294c9ed Mon Sep 17 00:00:00 2001 From: Nick Cameron Date: Thu, 3 Apr 2014 13:53:57 +1300 Subject: Add a span to ast::TyParam --- src/libsyntax/parse/parser.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/libsyntax/parse') 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 "" and "". 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, } } -- cgit 1.4.1-3-g733a5