mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-01 22:02:45 +01:00
Update toolchain keyword list to match design. (#2961)
- `xor` keyword is removed, with `^` used in its place. - For consistency, also replaced unary `~` with unary `^`, as those changes come from the same proposal. - `type` keyword is added. - To keep existing tests working, parsing support for `type` literal is added too. - `is` keyword is removed; we'd already added the `impls` keyword to the list. - Several other missing keywords added.
This commit is contained in:
@@ -70,7 +70,8 @@ auto ParserHandleExpressionInPostfix(ParserContext& context) -> void {
|
||||
case TokenKind::IntegerTypeLiteral:
|
||||
case TokenKind::UnsignedIntegerTypeLiteral:
|
||||
case TokenKind::FloatingPointTypeLiteral:
|
||||
case TokenKind::StringTypeLiteral: {
|
||||
case TokenKind::StringTypeLiteral:
|
||||
case TokenKind::Type: {
|
||||
context.AddLeafNode(ParseNodeKind::Literal, context.Consume());
|
||||
context.PushState(state);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user