mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 20:31:15 +01:00
Rename DotOrArrow to PeriodOrArrow (#4263)
We generally say Period (this is the only "Dot" in code), so this seems more consistent. Also renames a few struct tests that had "dot" in the name.
This commit is contained in:
@@ -35,10 +35,10 @@ static auto HandlePeriodOrArrow(Context& context, NodeKind node_kind,
|
||||
context.PushState(State::OnlyParenExpr);
|
||||
return;
|
||||
} else {
|
||||
CARBON_DIAGNOSTIC(ExpectedIdentifierAfterDotOrArrow, Error,
|
||||
CARBON_DIAGNOSTIC(ExpectedIdentifierAfterPeriodOrArrow, Error,
|
||||
"Expected identifier after `{0}`.", llvm::StringLiteral);
|
||||
context.emitter().Emit(
|
||||
*context.position(), ExpectedIdentifierAfterDotOrArrow,
|
||||
*context.position(), ExpectedIdentifierAfterPeriodOrArrow,
|
||||
is_arrow ? llvm::StringLiteral("->") : llvm::StringLiteral("."));
|
||||
// If we see a keyword, assume it was intended to be a name.
|
||||
// TODO: Should keywords be valid here?
|
||||
|
||||
Reference in New Issue
Block a user