From 4fbe5149856e4de2dc74ef4a5ae7c7903e388117 Mon Sep 17 00:00:00 2001 From: Nick Cameron Date: Thu, 17 Sep 2015 15:13:51 +1200 Subject: [PATCH] Fix the span for ! returns --- src/libsyntax/parse/parser.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index ff622859cf0b1..b6650b6f94420 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -1263,7 +1263,7 @@ impl<'a> Parser<'a> { pub fn parse_ret_ty(&mut self) -> PResult { if try!(self.eat(&token::RArrow) ){ if try!(self.eat(&token::Not) ){ - Ok(NoReturn(self.span)) + Ok(NoReturn(self.last_span)) } else { Ok(Return(try!(self.parse_ty_nopanic()))) }