Skip to content

Commit add9f8e

Browse files
committed
---
yaml --- r: 140162 b: refs/heads/try2 c: 5411cbf h: refs/heads/master v: v3
1 parent f47673a commit add9f8e

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 63397b8519c07a4714830a07368b1b044dbdac4b
8+
refs/heads/try2: 5411cbf656b42ef1d8a95e9de1a50bea616f7c56
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/src/libsyntax/parse/parser.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2433,8 +2433,7 @@ pub impl Parser {
24332433
}
24342434

24352435
// parse a local variable declaration
2436-
fn parse_local(&self, is_mutbl: bool,
2437-
allow_init: bool) -> @local {
2436+
fn parse_local(&self, is_mutbl: bool) -> @local {
24382437
let lo = self.span.lo;
24392438
let pat = self.parse_pat(false);
24402439
let mut ty = @Ty {
@@ -2443,7 +2442,7 @@ pub impl Parser {
24432442
span: mk_sp(lo, lo),
24442443
};
24452444
if self.eat(&token::COLON) { ty = self.parse_ty(false); }
2446-
let init = if allow_init { self.parse_initializer() } else { None };
2445+
let init = self.parse_initializer();
24472446
@spanned(
24482447
lo,
24492448
self.last_span.hi,
@@ -2460,9 +2459,9 @@ pub impl Parser {
24602459
fn parse_let(&self) -> @decl {
24612460
let is_mutbl = self.eat_keyword(&~"mut");
24622461
let lo = self.span.lo;
2463-
let mut locals = ~[self.parse_local(is_mutbl, true)];
2462+
let mut locals = ~[self.parse_local(is_mutbl)];
24642463
while self.eat(&token::COMMA) {
2465-
locals.push(self.parse_local(is_mutbl, true));
2464+
locals.push(self.parse_local(is_mutbl));
24662465
}
24672466
return @spanned(lo, self.last_span.hi, decl_local(locals));
24682467
}

0 commit comments

Comments
 (0)