mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-04 22:02:52 +01:00
Abbreviate Integer and FloatingPoint (#3435)
I was suggesting this because `FloatingPoint` is pretty long. `int` and `float` should be familiar abbreviations. `unsigned` should be familiar to developers too, but `UnsignedInt` still feels usefully clearer for the additional chars.
This commit is contained in:
@@ -241,8 +241,7 @@ auto Context::SkipTo(Lex::TokenIndex t) -> void {
|
||||
// operand according to the rules for infix operator parsing.
|
||||
static auto IsAssumedStartOfOperand(Lex::TokenKind kind) -> bool {
|
||||
return kind.IsOneOf({Lex::TokenKind::OpenParen, Lex::TokenKind::Identifier,
|
||||
Lex::TokenKind::IntegerLiteral,
|
||||
Lex::TokenKind::RealLiteral,
|
||||
Lex::TokenKind::IntLiteral, Lex::TokenKind::RealLiteral,
|
||||
Lex::TokenKind::StringLiteral});
|
||||
}
|
||||
|
||||
@@ -252,7 +251,7 @@ static auto IsAssumedEndOfOperand(Lex::TokenKind kind) -> bool {
|
||||
return kind.IsOneOf(
|
||||
{Lex::TokenKind::CloseParen, Lex::TokenKind::CloseCurlyBrace,
|
||||
Lex::TokenKind::CloseSquareBracket, Lex::TokenKind::Identifier,
|
||||
Lex::TokenKind::IntegerLiteral, Lex::TokenKind::RealLiteral,
|
||||
Lex::TokenKind::IntLiteral, Lex::TokenKind::RealLiteral,
|
||||
Lex::TokenKind::StringLiteral});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user