Skip to content

Commit 8ec67a1

Browse files
committed
Update availability checks
1 parent 10b11f6 commit 8ec67a1

File tree

6 files changed

+10
-10
lines changed

6 files changed

+10
-10
lines changed

Diff for: Sources/NIOCore/EventLoop+SerialExecutor.swift

+3-3
Original file line numberDiff line numberDiff line change
@@ -86,10 +86,10 @@ extension NIODefaultEventLoopExecutor: SerialExecutor {
8686
///
8787
/// Implementers of `EventLoop` should consider conforming to this protocol as
8888
/// well on Swift 6.0 and later.
89-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
89+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
9090
public protocol NIOTaskEventLoopExecutor: NIOSerialEventLoopExecutor & TaskExecutor { }
9191

92-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
92+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
9393
extension NIOTaskEventLoopExecutor {
9494
@inlinable
9595
func asUnownedTaskExecutor() -> UnownedTaskExecutor {
@@ -102,7 +102,7 @@ extension NIOTaskEventLoopExecutor {
102102
}
103103
}
104104

105-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
105+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
106106
extension NIODefaultEventLoopExecutor: TaskExecutor {
107107
@inlinable
108108
public func asUnownedTaskExecutor() -> UnownedTaskExecutor {

Diff for: Sources/NIOCore/EventLoop.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ extension EventLoop {
400400
#endif
401401

402402
#if compiler(>=6.0)
403-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
403+
@available(macOS 15.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
404404
public var taskExecutor: any TaskExecutor {
405405
NIODefaultEventLoopExecutor(self)
406406
}

Diff for: Sources/NIOEmbedded/AsyncTestingEventLoop.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ extension NIOAsyncTestingEventLoop: NIOSerialEventLoopExecutor { }
357357

358358
// MARK: TaskExecutor conformance
359359
#if compiler(>=6.0)
360-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
360+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
361361
extension NIOAsyncTestingEventLoop: NIOTaskEventLoopExecutor { }
362362
#endif
363363

Diff for: Sources/NIOEmbedded/Embedded.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ public final class EmbeddedEventLoop: EventLoop {
242242
#endif
243243

244244
#if compiler(>=6.0)
245-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
245+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
246246
public var taskExecutor: any TaskExecutor {
247247
fatalError("EmbeddedEventLoop is not thread safe and cannot be used as a TaskExecutor. Use NIOAsyncTestingEventLoop instead.")
248248
}

Diff for: Sources/NIOPosix/SelectableEventLoop.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -886,6 +886,6 @@ internal func assertExpression(_ body: () -> Bool) {
886886

887887
// MARK: TaskExecutor conformance
888888
#if compiler(>=6.0)
889-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
889+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
890890
extension SelectableEventLoop: NIOTaskEventLoopExecutor { }
891891
#endif

Diff for: Tests/NIOPosixTests/TaskExecutorTests.swift

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import XCTest
1919
final class TaskExecutorTests: XCTestCase {
2020

2121
#if compiler(>=6.0)
22-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
22+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
2323
func _runTests(loop1: some EventLoop, loop2: some EventLoop) async {
2424
await withTaskGroup(of: Void.self) { taskGroup in
2525
taskGroup.addTask(executorPreference: loop1.taskExecutor) {
@@ -57,7 +57,7 @@ final class TaskExecutorTests: XCTestCase {
5757
}
5858
#endif
5959

60-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
60+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
6161
func testSelectableEventLoopAsTaskExecutor() async throws {
6262
#if compiler(>=6.0)
6363
let group = MultiThreadedEventLoopGroup(numberOfThreads: 2)
@@ -72,7 +72,7 @@ final class TaskExecutorTests: XCTestCase {
7272
#endif
7373
}
7474

75-
@available(macOS 9999.0, iOS 9999.0, watchOS 9999.0, tvOS 9999.0, *)
75+
@available(macOS 15.0, iOS 18.0, tvOS 18.0, watchOS 11.0, *)
7676
func testAsyncTestingEventLoopAsTaskExecutor() async throws {
7777
#if compiler(>=6.0)
7878
let loop1 = NIOAsyncTestingEventLoop()

0 commit comments

Comments
 (0)