Skip to content

Commit 32bd60a

Browse files
committed
Make code compile for Swift 5.5
1 parent ba2b0f0 commit 32bd60a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/ASTGen/Sources/ASTGen/Diagnostics.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,10 @@ func emitDiagnostic(
124124
}
125125

126126
extension SourceManager {
127-
private func diagnoseSingle(
127+
private func diagnoseSingle<Node: SyntaxProtocol>(
128128
message: String,
129129
severity: DiagnosticSeverity,
130-
node: some SyntaxProtocol,
130+
node: Node,
131131
position: AbsolutePosition,
132132
highlights: [Syntax] = [],
133133
fixItChanges: [FixIt.Change] = []

lib/ASTGen/Sources/ASTGen/SourceManager.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ extension SourceManager {
136136

137137
var detached = context.detach(node)
138138

139-
if let operatorTable {
139+
if let operatorTable = operatorTable {
140140
detached = operatorTable.foldAll(node) { _ in }.as(Node.self)!
141141
}
142142

0 commit comments

Comments
 (0)