Skip to content

Commit e706aa9

Browse files
committed
Update to swift-syntax 600.0.1
1 parent fe6653d commit e706aa9

File tree

5 files changed

+18
-12
lines changed

5 files changed

+18
-12
lines changed

Package.resolved

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
"kind" : "remoteSourceControl",
1515
"location" : "https://github.com/swiftlang/swift-docc-plugin",
1616
"state" : {
17-
"revision" : "26ac5758409154cc448d7ab82389c520fa8a8247",
18-
"version" : "1.3.0"
17+
"revision" : "85e4bb4e1cd62cec64a4b8e769dcefdf0c5b9d64",
18+
"version" : "1.4.3"
1919
}
2020
},
2121
{
@@ -41,8 +41,8 @@
4141
"kind" : "remoteSourceControl",
4242
"location" : "https://github.com/pointfreeco/swift-snapshot-testing",
4343
"state" : {
44-
"revision" : "7b0bbbae90c41f848f90ac7b4df6c4f50068256d",
45-
"version" : "1.17.5"
44+
"revision" : "42a086182681cf661f5c47c9b7dc3931de18c6d7",
45+
"version" : "1.17.6"
4646
}
4747
},
4848
{
@@ -59,8 +59,8 @@
5959
"kind" : "remoteSourceControl",
6060
"location" : "https://github.com/jpsim/Yams.git",
6161
"state" : {
62-
"revision" : "0d9ee7ea8c4ebd4a489ad7a73d5c6cad55d6fed3",
63-
"version" : "5.0.6"
62+
"revision" : "3036ba9d69cf1fd04d433527bc339dc0dc75433d",
63+
"version" : "5.1.3"
6464
}
6565
}
6666
],

Package.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ let package = Package(
1515
dependencies: [
1616
.package(
1717
url: "https://github.com/swiftlang/swift-syntax.git",
18-
from: "600.0.0"
18+
from: "600.0.1"
1919
),
2020
.package(url: "https://github.com/swiftlang/swift-docc-plugin", from: "1.3.0"),
2121
.package(url: "https://github.com/SwiftPackageIndex/SPIManifest.git", from: "0.12.0"),
@@ -52,7 +52,7 @@ let package = Package(
5252
"MacroToolkit",
5353
.product(name: "MacroTesting", package: "swift-macro-testing"),
5454
.product(name: "SwiftSyntax", package: "swift-syntax"),
55-
.product(name: "SwiftSyntaxMacros", package: "swift-syntax")
55+
.product(name: "SwiftSyntaxMacros", package: "swift-syntax"),
5656
]
5757
),
5858
]

Sources/MacroToolkit/Function.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public struct Function {
3232
}
3333

3434
public var isThrowing: Bool {
35-
_syntax.signature.effectSpecifiers?.throwsClause?.throwsSpecifier != nil
35+
_syntax.signature.effectSpecifiers?.throwsClause != nil
3636
}
3737

3838
public var parameters: [FunctionParameter] {

Sources/MacroToolkit/SwiftSyntax+Extensions.swift

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,9 @@ extension FunctionDeclSyntax {
6767
public var effectSpecifiersOrDefault: FunctionEffectSpecifiersSyntax {
6868
signature.effectSpecifiers
6969
?? FunctionEffectSpecifiersSyntax(
70-
leadingTrivia: " ", asyncSpecifier: nil, throwsClause: nil
70+
leadingTrivia: " ",
71+
asyncSpecifier: nil,
72+
throwsClause: nil
7173
)
7274
}
7375

@@ -92,7 +94,12 @@ extension FunctionDeclSyntax {
9294
.with(
9395
\.effectSpecifiers,
9496
effectSpecifiersOrDefault
95-
.with(\.throwsClause, isPresent ? ThrowsClauseSyntax(throwsSpecifier: " throws") : nil)
97+
.with(
98+
\.throwsClause,
99+
isPresent
100+
? ThrowsClauseSyntax(throwsSpecifier: .keyword(.throws))
101+
: nil
102+
)
96103
)
97104
)
98105
}

Tests/MacroToolkitTests/MacroToolkitTests.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ final class MacroToolkitTests: XCTestCase {
2424
withMacroTesting(
2525
macros: testMacros
2626
) {
27-
isRecording = false
2827
super.invokeTest()
2928
}
3029
}

0 commit comments

Comments
 (0)