diff options
| author | Nick Cameron <ncameron@mozilla.com> | 2015-11-13 09:34:41 +1300 |
|---|---|---|
| committer | Nick Cameron <ncameron@mozilla.com> | 2015-11-13 09:34:41 +1300 |
| commit | 224c789ef26cea705d299cc160073879ad1be2b3 (patch) | |
| tree | 6002dedc34b63e1870f3b7aec03b7df5a33b2b3f /src/libsyntax/parse/parser.rs | |
| parent | 098ea175568b9bf4884985a729c211da4d913aed (diff) | |
| download | rust-224c789ef26cea705d299cc160073879ad1be2b3.tar.gz rust-224c789ef26cea705d299cc160073879ad1be2b3.zip | |
Fix a bad span for binops
Diffstat (limited to 'src/libsyntax/parse/parser.rs')
| -rw-r--r-- | src/libsyntax/parse/parser.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 1e38eebec5d..db61feb4113 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -2681,9 +2681,9 @@ impl<'a> Parser<'a> { // Semi-statement forms are odd. See https://github.com/rust-lang/rust/issues/29071 return Ok(lhs); } - let cur_op_span = self.span; self.expected_tokens.push(TokenType::Operator); while let Some(op) = AssocOp::from_token(&self.token) { + let cur_op_span = self.span; let restrictions = if op.is_assign_like() { self.restrictions & Restrictions::RESTRICTION_NO_STRUCT_LITERAL } else { |
