Skip to content

Commit 13baaa8

Browse files
authored
Drop inner @MainActor from withMainSerialExecutor (#28)
The inner operation is implicitly main actor, so no need to be explicit about it. Fixes #27.
1 parent 42e2ad3 commit 13baaa8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/ConcurrencyExtras/MainSerialExecutor.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
/// - Parameter operation: An operation to be performed on the main serial executor.
3030
@MainActor
3131
public func withMainSerialExecutor(
32-
@_implicitSelfCapture operation: @MainActor @Sendable () async throws -> Void
32+
@_implicitSelfCapture operation: @Sendable () async throws -> Void
3333
) async rethrows {
3434
let didUseMainSerialExecutor = uncheckedUseMainSerialExecutor
3535
defer { uncheckedUseMainSerialExecutor = didUseMainSerialExecutor }

0 commit comments

Comments
 (0)