Skip to content

Commit 16977f9

Browse files
committed
Migrate one case to expectContextualKeywordWithoutRecovery
1 parent 72ee35c commit 16977f9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sources/SwiftParser/Expressions.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1981,9 +1981,9 @@ extension Parser {
19811981
if let lparen = self.consume(if: .leftParen) {
19821982
specifiers.append(lparen)
19831983
if self.currentToken.tokenText == "safe" {
1984-
specifiers.append(self.expectWithoutRecovery(.identifier, where: { $0.tokenText == "safe" }))
1984+
specifiers.append(self.expectContextualKeywordWithoutRecovery("safe"))
19851985
} else {
1986-
specifiers.append(self.expectWithoutRecovery(.identifier, where: { $0.tokenText == "unsafe" }))
1986+
specifiers.append(self.expectContextualKeywordWithoutRecovery("unsafe"))
19871987
}
19881988
specifiers.append(self.expectWithoutRecovery(.rightParen))
19891989
}

0 commit comments

Comments
 (0)