Skip to content

Commit 25e423c

Browse files
authored
Merge pull request swiftlang#17 from owenv/owenv/consistent-access
withTimeout overloads should have consistent package access
2 parents 45095d1 + 0b6422c commit 25e423c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sources/ToolsProtocolsSwiftExtensions/AsyncUtils.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ extension Collection where Self: Sendable, Element: Sendable {
205205
///
206206
/// If a `handle` is passed in and this `withTimeout` call times out, the thrown `TimeoutError` contains this handle.
207207
/// This way a caller can identify whether this call to `withTimeout` timed out or if a nested call timed out.
208-
@_spi(SourceKitLSP) public func withTimeout<T: Sendable>(
208+
package func withTimeout<T: Sendable>(
209209
_ duration: Duration,
210210
handle: TimeoutHandle? = nil,
211211
_ body: @escaping @Sendable () async throws -> T
@@ -271,7 +271,7 @@ extension Collection where Self: Sendable, Element: Sendable {
271271
///
272272
/// - Important: `body` will not be cancelled when the timeout is received. Use the other overload of `withTimeout` if
273273
/// `body` should be cancelled after `timeout`.
274-
@_spi(SourceKitLSP) public func withTimeout<T: Sendable>(
274+
package func withTimeout<T: Sendable>(
275275
_ timeout: Duration,
276276
body: @escaping @Sendable () async throws -> T,
277277
resultReceivedAfterTimeout: @escaping @Sendable (_ result: T) async -> Void

0 commit comments

Comments
 (0)