Skip to content

Commit 23e3442

Browse files
Kolos65mbrandonw
andauthored
Fix Swift 5.10 toolchain issue on Linux builds (#159)
* Fix Swift 5.10 toolchain issue on Linux builds * Apply suggestion from @mbrandonw --------- Co-authored-by: Brandon Williams <135203+mbrandonw@users.noreply.github.com>
1 parent 230c960 commit 23e3442

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Sources/IssueReporting/ErrorReporting.swift

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
// swift-format-ignore-file
2+
// Note: Whitespace changes are used to workaround compiler bug
3+
// https://github.com/swiftlang/swift/issues/79285
4+
15
/// Evaluates a throwing closure and automatically catches and reports any error thrown.
26
///
37
/// - Parameters:
@@ -74,8 +78,9 @@ public func withErrorReporting<R>(
7478
line: UInt = #line,
7579
column: UInt = #column,
7680
isolation: isolated (any Actor)? = #isolation,
77-
catching body: () async throws -> sending R
78-
) async -> R? {
81+
// DO NOT FIX THE WHITESPACE IN THE NEXT LINE UNTIL 5.10 IS UNSUPPORTED
82+
// https://github.com/swiftlang/swift/issues/79285
83+
catching body: () async throws -> sending R) async -> R? {
7984
if let reporters {
8085
return await withIssueReporters(reporters) {
8186
do {

0 commit comments

Comments
 (0)