Skip to content

Commit f87ecde

Browse files
authored
Merge pull request #385 from allevato/async-contextual-keyword
Update for `async` being a contextual keyword.
2 parents 0349863 + 4724c19 commit f87ecde

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SwiftFormatPrettyPrint/TokenStreamCreator.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1719,7 +1719,7 @@ fileprivate final class TokenStreamCreator: SyntaxVisitor {
17191719
// this special exception for `async let` statements to avoid breaking prematurely between the
17201720
// `async` and `let` keywords.
17211721
let breakOrSpace: Token
1722-
if node.name.tokenKind == .identifier("async") {
1722+
if node.name.tokenKind == .contextualKeyword("async") {
17231723
breakOrSpace = .space
17241724
} else {
17251725
breakOrSpace = .break

0 commit comments

Comments
 (0)