@@ -36,11 +36,9 @@ public protocol Executor: AnyObject, Sendable {
3636 func enqueue( _ job: consuming ExecutorJob )
3737 #endif // !SWIFT_STDLIB_TASK_TO_THREAD_MODEL_CONCURRENCY
3838
39- #if !$Embedded
4039 /// `true` if this is the main executor.
4140 @available ( StdlibDeploymentTarget 6 . 2 , * )
4241 var isMainExecutor : Bool { get }
43- #endif
4442}
4543
4644@available ( StdlibDeploymentTarget 6 . 2 , * )
@@ -145,12 +143,10 @@ extension Executor where Self: Equatable {
145143
146144extension Executor {
147145
148- #if !$Embedded
149146 // This defaults to `false` so that existing third-party Executor
150147 // implementations will work as expected.
151148 @available ( StdlibDeploymentTarget 6 . 2 , * )
152149 public var isMainExecutor : Bool { false }
153- #endif
154150
155151}
156152
@@ -368,7 +364,7 @@ public protocol SerialExecutor: Executor {
368364@available ( StdlibDeploymentTarget 6 . 0 , * )
369365extension SerialExecutor {
370366
371- #if !$Embedded && ! SWIFT_STDLIB_TASK_TO_THREAD_MODEL_CONCURRENCY
367+ #if !SWIFT_STDLIB_TASK_TO_THREAD_MODEL_CONCURRENCY
372368 @available ( StdlibDeploymentTarget 6 . 2 , * )
373369 public var isMainExecutor : Bool { return MainActor . executor. _isSameExecutor ( self ) }
374370 #endif
@@ -579,11 +575,9 @@ public protocol MainExecutor: RunLoopExecutor, SerialExecutor {
579575/// executors.
580576@available ( StdlibDeploymentTarget 6 . 2 , * )
581577public protocol ExecutorFactory {
582- #if !$Embedded
583578 /// Constructs and returns the main executor, which is started implicitly
584579 /// by the `async main` entry point and owns the "main" thread.
585580 static var mainExecutor : any MainExecutor { get }
586- #endif
587581
588582 /// Constructs and returns the default or global executor, which is the
589583 /// default place in which we run tasks.
@@ -596,7 +590,7 @@ typealias DefaultExecutorFactory = PlatformExecutorFactory
596590@available ( StdlibDeploymentTarget 6 . 2 , * )
597591@_silgen_name ( " swift_createExecutors " )
598592public func _createExecutors< F: ExecutorFactory > ( factory: F . Type ) {
599- #if !$Embedded && ! SWIFT_STDLIB_TASK_TO_THREAD_MODEL_CONCURRENCY
593+ #if !SWIFT_STDLIB_TASK_TO_THREAD_MODEL_CONCURRENCY
600594 MainActor . _executor = factory. mainExecutor
601595 #endif
602596 Task . _defaultExecutor = factory. defaultExecutor
0 commit comments