File tree Expand file tree Collapse file tree 2 files changed +9
-17
lines changed
branches/snap-stage3/src/libsyntax/parse Expand file tree Collapse file tree 2 files changed +9
-17
lines changed Original file line number Diff line number Diff line change 1
1
---
2
2
refs/heads/master: e430a699f2c60890d9b86069fd0c68a70ece7120
3
3
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4
- refs/heads/snap-stage3: 4991cc5d19a61da91345e9a324c0ea4b8d1b923d
4
+ refs/heads/snap-stage3: fd536d9d3e5a54b0a7b551a795198210fc229da3
5
5
refs/heads/try: ffbe0e0e00374358b789b0037bcb3a577cd218be
6
6
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
7
7
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
Original file line number Diff line number Diff line change @@ -1693,7 +1693,7 @@ class parser {
1693
1693
}
1694
1694
}
1695
1695
tok {
1696
- if ( !is_ident ( tok) && tok != token :: BINOP ( token :: PLUS ) ) ||
1696
+ if !is_ident( tok) ||
1697
1697
self . is_keyword ( ~"true ") || self . is_keyword ( ~"false ") {
1698
1698
let val = self . parse_expr_res ( RESTRICT_NO_BAR_OP ) ;
1699
1699
if self . eat_keyword ( ~"to") {
@@ -1708,22 +1708,14 @@ class parser {
1708
1708
let binding_mode;
1709
1709
if self . eat_keyword ( ~"ref ") {
1710
1710
binding_mode = bind_by_ref;
1711
+ } else if self . eat_keyword ( ~"copy") {
1712
+ binding_mode = bind_by_value;
1713
+ } else if refutable {
1714
+ // XXX: Should be bind_by_value, but that's not
1715
+ // backward compatible.
1716
+ binding_mode = bind_by_ref;
1711
1717
} else {
1712
- alt self . token {
1713
- token:: BINOP ( token:: PLUS ) => {
1714
- // XXX: Temporary thing pending a snapshot.
1715
- self . bump ( ) ;
1716
- binding_mode = bind_by_value;
1717
- }
1718
- _ if refutable => {
1719
- // XXX: Should be bind_by_value, but that's not
1720
- // backward compatible.
1721
- binding_mode = bind_by_ref;
1722
- }
1723
- _ => {
1724
- binding_mode = bind_by_value;
1725
- }
1726
- }
1718
+ binding_mode = bind_by_value;
1727
1719
}
1728
1720
1729
1721
if is_plain_ident ( self . token ) &&
You can’t perform that action at this time.
0 commit comments