diff options
| author | bors <bors@rust-lang.org> | 2014-04-04 16:01:44 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-04-04 16:01:44 -0700 |
| commit | 4cf8d8ce69c1d1d10e90b04230d4c4e8dbb67bcc (patch) | |
| tree | 61f1237167d3663ba874e2b802cd9f5dd3c57041 /src/libsyntax/parse | |
| parent | e5f1b9f6dc9418325f83d9766c7cfab30cb48018 (diff) | |
| parent | 6d43138b75f009bfa6f0774953ef55fd91e9760a (diff) | |
| download | rust-4cf8d8ce69c1d1d10e90b04230d4c4e8dbb67bcc.tar.gz rust-4cf8d8ce69c1d1d10e90b04230d4c4e8dbb67bcc.zip | |
auto merge of #13326 : alexcrichton/rust/rollup, r=alexcrichton
Closes #13313 (Fix typo in README.md) Closes #13311 (Fix inner attribute syntax from `#[foo];` to `#![foo]`) Closes #13309 (Add stdlib docs to the Linux binary tarball.) Closes #13308 (syntax: remove obsolete mutability from ExprVec and ExprRepeat.) Closes #13306 (TrieSet should impl Set/MutableSet; add with_capacity to PriorityQueue/SmallIntMap) Closes #13303 (Register new snapshots) Closes #13274 (Added grow_fn and retain to Vec) *Issues Closed* Closes #13249
Diffstat (limited to 'src/libsyntax/parse')
| -rw-r--r-- | src/libsyntax/parse/parser.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 2d78bfe5694..94f5458ba53 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -1819,12 +1819,11 @@ impl<'a> Parser<'a> { return self.parse_block_expr(lo, UnsafeBlock(ast::UserProvided)); } else if self.token == token::LBRACKET { self.bump(); - let mutbl = MutImmutable; if self.token == token::RBRACKET { // Empty vector. self.bump(); - ex = ExprVec(Vec::new(), mutbl); + ex = ExprVec(Vec::new()); } else { // Nonempty vector. let first_expr = self.parse_expr(); @@ -1835,7 +1834,7 @@ impl<'a> Parser<'a> { self.bump(); let count = self.parse_expr(); self.expect(&token::RBRACKET); - ex = ExprRepeat(first_expr, count, mutbl); + ex = ExprRepeat(first_expr, count); } else if self.token == token::COMMA { // Vector with two or more elements. self.bump(); @@ -1846,11 +1845,11 @@ impl<'a> Parser<'a> { ); let mut exprs = vec!(first_expr); exprs.push_all_move(remaining_exprs); - ex = ExprVec(exprs, mutbl); + ex = ExprVec(exprs); } else { // Vector with one element. self.expect(&token::RBRACKET); - ex = ExprVec(vec!(first_expr), mutbl); + ex = ExprVec(vec!(first_expr)); } } hi = self.last_span.hi; |
