Update availability checks for async function for all supported platforms (#118)

This commit is contained in:
Tobias authored and GitHub committed 2022-01-05 17:21:42 -08:00
1 parent da0cb159aa
commit 2bc97b030e
1 file changed
+6 -6
+6 -6
View File
@@ -95,8 +95,8 @@ public struct LifecycleHandler {
}
}
#if compiler(>=5.5) && canImport(_Concurrency)
@available(macOS 12.0, *)
#if canImport(_Concurrency) && compiler(>=5.5.2)
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
extension LifecycleHandler {
public init(_ handler: @escaping () async throws -> Void) {
self = LifecycleHandler { callback in
@@ -159,8 +159,8 @@ public struct LifecycleStartHandler<State> {
}
}
#if compiler(>=5.5) && canImport(_Concurrency)
@available(macOS 12.0, *)
#if canImport(_Concurrency) && compiler(>=5.5.2)
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
extension LifecycleStartHandler {
public init(_ handler: @escaping () async throws -> State) {
self = LifecycleStartHandler { callback in
@@ -221,8 +221,8 @@ public struct LifecycleShutdownHandler<State> {
}
}
#if compiler(>=5.5) && canImport(_Concurrency)
@available(macOS 12.0, *)
#if canImport(_Concurrency) && compiler(>=5.5.2)
@available(macOS 10.15, iOS 13, tvOS 13, watchOS 6, *)
extension LifecycleShutdownHandler {
public init(_ handler: @escaping (State) async throws -> Void) {
self = LifecycleShutdownHandler { state, callback in