From 044ad56824e81865d3b46f812b815f355388a716 Mon Sep 17 00:00:00 2001 From: Patrick Walton Date: Mon, 30 Dec 2013 15:30:56 -0800 Subject: libsyntax: De-`@mut` `Parser::last_token` --- src/libsyntax/parse/parser.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/libsyntax/parse/parser.rs') diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 0f4cc2ae5cd..467c6f2d81e 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -304,7 +304,7 @@ pub fn Parser(sess: @mut ParseSess, cfg: ast::CrateConfig, rdr: @mut reader) token: tok0.tok, span: span, last_span: span, - last_token: @mut None, + last_token: None, buffer: @mut ([ placeholder.clone(), placeholder.clone(), @@ -334,7 +334,7 @@ pub struct Parser { // the span of the prior token: last_span: Span, // the previous token or None (only stashed sometimes). - last_token: @mut Option<~token::Token>, + last_token: Option<~token::Token>, buffer: @mut [TokenAndSpan, ..4], buffer_start: @mut int, buffer_end: @mut int, @@ -728,7 +728,7 @@ impl Parser { pub fn bump(&mut self) { self.last_span = self.span; // Stash token for error recovery (sometimes; clone is not necessarily cheap). - *self.last_token = if is_ident_or_path(&self.token) { + self.last_token = if is_ident_or_path(&self.token) { Some(~self.token.clone()) } else { None -- cgit 1.4.1-3-g733a5