Skip to content

Commit 599ba41

Browse files
authored
Merge pull request #273 from slavapestov/reasync
Update for 'reasync'
2 parents a63ff98 + cb3cefd commit 599ba41

File tree

4 files changed

+15
-15
lines changed

4 files changed

+15
-15
lines changed

Sources/SwiftSyntax/gyb_generated/Misc.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1952,6 +1952,6 @@ extension Syntax {
19521952
extension SyntaxParser {
19531953
static func verifyNodeDeclarationHash() -> Bool {
19541954
return String(cString: swiftparse_syntax_structure_versioning_identifier()!) ==
1955-
"20b92b603651f0f0f61d43f86e4c706a8a118216"
1955+
"a64f1ebd5d8a9b198af660d99d4ba7345b773b3d"
19561956
}
19571957
}

Sources/SwiftSyntax/gyb_generated/SyntaxBuilders.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3369,8 +3369,8 @@ public struct FunctionSignatureSyntaxBuilder {
33693369
layout[idx] = node.raw
33703370
}
33713371

3372-
public mutating func useAsyncKeyword(_ node: TokenSyntax) {
3373-
let idx = FunctionSignatureSyntax.Cursor.asyncKeyword.rawValue
3372+
public mutating func useAsyncOrReasyncKeyword(_ node: TokenSyntax) {
3373+
let idx = FunctionSignatureSyntax.Cursor.asyncOrReasyncKeyword.rawValue
33743374
layout[idx] = node.raw
33753375
}
33763376

Sources/SwiftSyntax/gyb_generated/SyntaxFactory.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1587,10 +1587,10 @@ public enum SyntaxFactory {
15871587
], length: .zero, presence: .present))
15881588
return ReturnClauseSyntax(data)
15891589
}
1590-
public static func makeFunctionSignature(input: ParameterClauseSyntax, asyncKeyword: TokenSyntax?, throwsOrRethrowsKeyword: TokenSyntax?, output: ReturnClauseSyntax?) -> FunctionSignatureSyntax {
1590+
public static func makeFunctionSignature(input: ParameterClauseSyntax, asyncOrReasyncKeyword: TokenSyntax?, throwsOrRethrowsKeyword: TokenSyntax?, output: ReturnClauseSyntax?) -> FunctionSignatureSyntax {
15911591
let layout: [RawSyntax?] = [
15921592
input.raw,
1593-
asyncKeyword?.raw,
1593+
asyncOrReasyncKeyword?.raw,
15941594
throwsOrRethrowsKeyword?.raw,
15951595
output?.raw,
15961596
]

Sources/SwiftSyntax/gyb_generated/syntax_nodes/SyntaxNodes.swift

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2638,7 +2638,7 @@ extension ReturnClauseSyntax: CustomReflectable {
26382638
public struct FunctionSignatureSyntax: SyntaxProtocol, SyntaxHashable {
26392639
enum Cursor: Int {
26402640
case input
2641-
case asyncKeyword
2641+
case asyncOrReasyncKeyword
26422642
case throwsOrRethrowsKeyword
26432643
case output
26442644
}
@@ -2685,25 +2685,25 @@ public struct FunctionSignatureSyntax: SyntaxProtocol, SyntaxHashable {
26852685
return FunctionSignatureSyntax(newData)
26862686
}
26872687

2688-
public var asyncKeyword: TokenSyntax? {
2688+
public var asyncOrReasyncKeyword: TokenSyntax? {
26892689
get {
2690-
let childData = data.child(at: Cursor.asyncKeyword,
2690+
let childData = data.child(at: Cursor.asyncOrReasyncKeyword,
26912691
parent: Syntax(self))
26922692
if childData == nil { return nil }
26932693
return TokenSyntax(childData!)
26942694
}
26952695
set(value) {
2696-
self = withAsyncKeyword(value)
2696+
self = withAsyncOrReasyncKeyword(value)
26972697
}
26982698
}
26992699

2700-
/// Returns a copy of the receiver with its `asyncKeyword` replaced.
2701-
/// - param newChild: The new `asyncKeyword` to replace the node's
2702-
/// current `asyncKeyword`, if present.
2703-
public func withAsyncKeyword(
2700+
/// Returns a copy of the receiver with its `asyncOrReasyncKeyword` replaced.
2701+
/// - param newChild: The new `asyncOrReasyncKeyword` to replace the node's
2702+
/// current `asyncOrReasyncKeyword`, if present.
2703+
public func withAsyncOrReasyncKeyword(
27042704
_ newChild: TokenSyntax?) -> FunctionSignatureSyntax {
27052705
let raw = newChild?.raw
2706-
let newData = data.replacingChild(raw, at: Cursor.asyncKeyword)
2706+
let newData = data.replacingChild(raw, at: Cursor.asyncOrReasyncKeyword)
27072707
return FunctionSignatureSyntax(newData)
27082708
}
27092709

@@ -2795,7 +2795,7 @@ extension FunctionSignatureSyntax: CustomReflectable {
27952795
public var customMirror: Mirror {
27962796
return Mirror(self, children: [
27972797
"input": Syntax(input).asProtocol(SyntaxProtocol.self),
2798-
"asyncKeyword": asyncKeyword.map(Syntax.init)?.asProtocol(SyntaxProtocol.self) as Any,
2798+
"asyncOrReasyncKeyword": asyncOrReasyncKeyword.map(Syntax.init)?.asProtocol(SyntaxProtocol.self) as Any,
27992799
"throwsOrRethrowsKeyword": throwsOrRethrowsKeyword.map(Syntax.init)?.asProtocol(SyntaxProtocol.self) as Any,
28002800
"output": output.map(Syntax.init)?.asProtocol(SyntaxProtocol.self) as Any,
28012801
])

0 commit comments

Comments
 (0)