Skip to content

Commit 7777ed5

Browse files
committed
[Parser] NFC: Rename isAllowedInProtocolRequirement -> isAllowedWhenParsingLimitedSyntax
1 parent aabd1b7 commit 7777ed5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/Parse/ParseDecl.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7281,7 +7281,7 @@ static void diagnoseRedundantAccessors(Parser &P, SourceLoc loc,
72817281
/*already*/ true);
72827282
}
72837283

7284-
static bool isAllowedInProtocolRequirement(AccessorKind kind, bool forSIL) {
7284+
static bool isAllowedWhenParsingLimitedSyntax(AccessorKind kind, bool forSIL) {
72857285
switch (kind) {
72867286
case AccessorKind::Get:
72877287
case AccessorKind::Set:
@@ -7690,8 +7690,8 @@ ParserStatus Parser::parseGetSet(ParseDeclOptions Flags, ParameterList *Indices,
76907690

76917691
// For now, immediately reject illegal accessors in protocols just to
76927692
// avoid having to deal with them everywhere.
7693-
if (parsingLimitedSyntax &&
7694-
!isAllowedInProtocolRequirement(Kind, SF.Kind == SourceFileKind::SIL)) {
7693+
if (parsingLimitedSyntax && !isAllowedWhenParsingLimitedSyntax(
7694+
Kind, SF.Kind == SourceFileKind::SIL)) {
76957695
diagnose(Loc, diag::expected_getset_in_protocol);
76967696
continue;
76977697
}

0 commit comments

Comments
 (0)