diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-09-18 11:17:49 -0700 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-09-18 11:31:58 -0700 |
| commit | d0d8b7fe6491d539254d281f39a6c0aa0261e42d (patch) | |
| tree | 5a2c8285f9c49a245e87b8888367e4a6ee1c5c15 /src/libsyntax/parse | |
| parent | 2cdb23bbc08fba2f5dc7b0dcc79983fc02e32960 (diff) | |
| download | rust-d0d8b7fe6491d539254d281f39a6c0aa0261e42d.tar.gz rust-d0d8b7fe6491d539254d281f39a6c0aa0261e42d.zip | |
Remove 'unchecked' keyword
Diffstat (limited to 'src/libsyntax/parse')
| -rw-r--r-- | src/libsyntax/parse/parser.rs | 9 | ||||
| -rw-r--r-- | src/libsyntax/parse/token.rs | 2 |
2 files changed, 2 insertions, 9 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index fa506a062b4..dd3e9093166 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -926,8 +926,6 @@ impl parser { _ => { /* fallthrough */ } } return pexpr(self.parse_fn_expr(proto)); - } else if self.eat_keyword(~"unchecked") { - return pexpr(self.parse_block_expr(lo, unchecked_blk)); } else if self.eat_keyword(~"unsafe") { return pexpr(self.parse_block_expr(lo, unsafe_blk)); } else if self.token == token::LBRACKET { @@ -2210,12 +2208,7 @@ impl parser { } let lo = self.span.lo; - if self.eat_keyword(~"unchecked") { - self.expect(token::LBRACE); - let {inner, next} = maybe_parse_inner_attrs_and_next(self, - parse_attrs); - return (inner, self.parse_block_tail_(lo, unchecked_blk, next)); - } else if self.eat_keyword(~"unsafe") { + if self.eat_keyword(~"unsafe") { self.expect(token::LBRACE); let {inner, next} = maybe_parse_inner_attrs_and_next(self, parse_attrs); diff --git a/src/libsyntax/parse/token.rs b/src/libsyntax/parse/token.rs index 0c4daf0a6e5..9ba30f75aea 100644 --- a/src/libsyntax/parse/token.rs +++ b/src/libsyntax/parse/token.rs @@ -439,7 +439,7 @@ fn strict_keyword_table() -> HashMap<~str, ()> { ~"ref", ~"return", ~"struct", ~"true", ~"trait", ~"type", - ~"unchecked", ~"use", + ~"use", ~"while" ]; for keys.each |word| { |
