Skip to content

Commit d06f828

Browse files
authored
Merge pull request #17 from GoodRequest/remove-sendable
Remove @sendable annotations from @mainactor typealiases
2 parents aaa5041 + a193506 commit d06f828

1 file changed

Lines changed: 15 additions & 15 deletions

File tree

Sources/GoodExtensions/Typealiases/Typealiases.swift

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public typealias NonSendableBiConsumer<T, U> = (T, U) -> ()
3232
public typealias NonSendablePredicate<T> = (T) -> Bool
3333
public typealias NonSendableFunction<T, U> = (T) -> (U)
3434

35-
// MARK: Regular + throwing
35+
// MARK: Throwing
3636

3737
public typealias ThrowingVoidClosure<E> = @Sendable () throws(E) -> ()
3838
public typealias ThrowingSupplier<T, E> = @Sendable () throws(E) -> (T)
@@ -41,20 +41,20 @@ public typealias ThrowingBiConsumer<T, U, E> = @Sendable (T, U) throws(E) -> ()
4141
public typealias ThrowingPredicate<T, E> = @Sendable (T) throws(E) -> Bool
4242
public typealias ThrowingFunction<T, U, E> = @Sendable (T) throws(E) -> (U)
4343

44-
// MARK: Regular + MainActor
44+
// MARK: MainActor
4545

46-
public typealias MainClosure = @MainActor @Sendable () -> ()
47-
public typealias MainSupplier<T> = @MainActor @Sendable () -> (T)
48-
public typealias MainConsumer<T> = @MainActor @Sendable (T) -> ()
49-
public typealias MainBiConsumer<T, U> = @MainActor @Sendable (T, U) -> ()
50-
public typealias MainPredicate<T> = @MainActor @Sendable (T) -> Bool
51-
public typealias MainFunction<T, U> = @MainActor @Sendable (T) -> (U)
46+
public typealias MainClosure = @MainActor () -> ()
47+
public typealias MainSupplier<T> = @MainActor () -> (T)
48+
public typealias MainConsumer<T> = @MainActor (T) -> ()
49+
public typealias MainBiConsumer<T, U> = @MainActor (T, U) -> ()
50+
public typealias MainPredicate<T> = @MainActor (T) -> Bool
51+
public typealias MainFunction<T, U> = @MainActor (T) -> (U)
5252

53-
// MARK: Regular + MainActor + throwing
53+
// MARK: MainActor + Throwing
5454

55-
public typealias MainThrowingVoidClosure<E> = @MainActor @Sendable () throws(E) -> ()
56-
public typealias MainThrowingSupplier<T, E> = @MainActor @Sendable () throws(E) -> (T)
57-
public typealias MainThrowingConsumer<T, E> = @MainActor @Sendable (T) throws(E) -> ()
58-
public typealias MainThrowingBiConsumer<T, U, E> = @MainActor @Sendable (T, U) throws(E) -> ()
59-
public typealias MainThrowingPredicate<T, E> = @MainActor @Sendable (T) throws(E) -> Bool
60-
public typealias MainThrowingFunction<T, U, E> = @MainActor @Sendable (T) throws(E) -> (U)
55+
public typealias MainThrowingVoidClosure<E> = @MainActor () throws(E) -> ()
56+
public typealias MainThrowingSupplier<T, E> = @MainActor () throws(E) -> (T)
57+
public typealias MainThrowingConsumer<T, E> = @MainActor (T) throws(E) -> ()
58+
public typealias MainThrowingBiConsumer<T, U, E> = @MainActor (T, U) throws(E) -> ()
59+
public typealias MainThrowingPredicate<T, E> = @MainActor (T) throws(E) -> Bool
60+
public typealias MainThrowingFunction<T, U, E> = @MainActor (T) throws(E) -> (U)

0 commit comments

Comments
 (0)