Skip to content

Commit 6bfac1e

Browse files
committed
Remove unnecessary .cast call in SwiftRewriter
1 parent b474940 commit 6bfac1e

File tree

2 files changed

+158
-158
lines changed

2 files changed

+158
-158
lines changed

CodeGeneration/Sources/generate-swift-syntax/templates/swiftsyntax/SyntaxRewriterFile.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ let syntaxRewriterFile = SourceFileSyntax(leadingTrivia: copyrightHeader) {
127127
/// - Returns: the rewritten node
128128
\(node.apiAttributes())\
129129
open func visit(_ node: \(node.kind.syntaxType)) -> \(node.kind.syntaxType) {
130-
return Syntax(visitChildren(node)).cast(\(node.kind.syntaxType).self)
130+
return visitChildren(node)
131131
}
132132
"""
133133
)

0 commit comments

Comments
 (0)