Skip to content

Commit 7e00fe4

Browse files
committed
[embedded] Use hasFeature(Embedded) instead of in TaskGroup.swift+DiscardingTaskGroup.swift
1 parent a2dcb60 commit 7e00fe4

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

stdlib/public/Concurrency/DiscardingTaskGroup.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ import Swift
6767
///
6868
/// - SeeAlso: ``withThrowingDiscardingTaskGroup(returning:body:)``
6969
@available(SwiftStdlib 5.9, *)
70-
#if !$Embedded
70+
#if !hasFeature(Embedded)
7171
@backDeployed(before: SwiftStdlib 6.0)
7272
#endif
7373
@inlinable
@@ -611,7 +611,7 @@ extension DiscardingTaskGroup: Sendable { }
611611
/// }
612612
/// ```
613613
@available(SwiftStdlib 5.9, *)
614-
#if !$Embedded
614+
#if !hasFeature(Embedded)
615615
@backDeployed(before: SwiftStdlib 6.0)
616616
#endif
617617
@inlinable

stdlib/public/Concurrency/TaskGroup.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ import Swift
6363
/// For tasks that need to handle cancellation by throwing an error,
6464
/// use the `withThrowingTaskGroup(of:returning:body:)` method instead.
6565
@available(SwiftStdlib 5.1, *)
66-
#if !$Embedded
66+
#if !hasFeature(Embedded)
6767
@backDeployed(before: SwiftStdlib 6.0)
6868
#endif
6969
@inlinable
@@ -200,7 +200,7 @@ public func _unsafeInheritExecutor_withTaskGroup<ChildTaskResult, GroupResult>(
200200
/// which gives you a chance to handle the individual error
201201
/// or to let the group rethrow the error.
202202
@available(SwiftStdlib 5.1, *)
203-
#if !$Embedded
203+
#if !hasFeature(Embedded)
204204
@backDeployed(before: SwiftStdlib 6.0)
205205
#endif
206206
@inlinable
@@ -596,7 +596,7 @@ public struct TaskGroup<ChildTaskResult: Sendable> {
596596
///
597597
/// - Returns: The value returned by the next child task that completes.
598598
@available(SwiftStdlib 5.1, *)
599-
#if !$Embedded
599+
#if !hasFeature(Embedded)
600600
@backDeployed(before: SwiftStdlib 6.0)
601601
#endif
602602
public mutating func next(isolation: isolated (any Actor)? = #isolation) async -> ChildTaskResult? {
@@ -616,7 +616,7 @@ public struct TaskGroup<ChildTaskResult: Sendable> {
616616
/// Await all of the pending tasks added this group.
617617
@usableFromInline
618618
@available(SwiftStdlib 5.1, *)
619-
#if !$Embedded
619+
#if !hasFeature(Embedded)
620620
@backDeployed(before: SwiftStdlib 6.0)
621621
#endif
622622
internal mutating func awaitAllRemainingTasks(isolation: isolated (any Actor)? = #isolation) async {
@@ -758,7 +758,7 @@ public struct ThrowingTaskGroup<ChildTaskResult: Sendable, Failure: Error> {
758758
/// Await all the remaining tasks on this group.
759759
@usableFromInline
760760
@available(SwiftStdlib 5.1, *)
761-
#if !$Embedded
761+
#if !hasFeature(Embedded)
762762
@backDeployed(before: SwiftStdlib 6.0)
763763
#endif
764764
internal mutating func awaitAllRemainingTasks(isolation: isolated (any Actor)? = #isolation) async {
@@ -1038,7 +1038,7 @@ public struct ThrowingTaskGroup<ChildTaskResult: Sendable, Failure: Error> {
10381038
///
10391039
/// - SeeAlso: `nextResult()`
10401040
@available(SwiftStdlib 5.1, *)
1041-
#if !$Embedded
1041+
#if !hasFeature(Embedded)
10421042
@backDeployed(before: SwiftStdlib 6.0)
10431043
#endif
10441044
public mutating func next(isolation: isolated (any Actor)? = #isolation) async throws -> ChildTaskResult? {

0 commit comments

Comments
 (0)