File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
stdlib/public/Concurrency Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ import Swift
3535/// before returning from this function:
3636///
3737/// ```
38- /// await withDiscardingTaskGroup { group in
38+ /// await withDiscardingTaskGroup(...) { group in
3939/// group.addTask { /* slow-task */ }
4040/// // slow-task executes...
4141/// }
@@ -357,7 +357,7 @@ extension DiscardingTaskGroup: Sendable { }
357357/// before returning from this function:
358358///
359359/// ```
360- /// try await withThrowingDiscardingTaskGroup { group in
360+ /// try await withThrowingDiscardingTaskGroup(of: Void.self) { group in
361361/// group.addTask { /* slow-task */ }
362362/// // slow-task executes...
363363/// }
@@ -390,7 +390,7 @@ extension DiscardingTaskGroup: Sendable { }
390390///
391391/// ```
392392/// // ThrowingTaskGroup, pattern not applicable to ThrowingDiscardingTaskGroup
393- /// try await withThrowingTaskGroup { group in
393+ /// try await withThrowingTaskGroup(of: Void.self) { group in
394394/// group.addTask { try boom() }
395395/// try await group.next() // re-throws "boom"
396396/// }
Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ using FutureFragment = AsyncTask::FutureFragment;
8989
9090// / During evolution discussions we opted to implement the following semantic of
9191// / a discarding task-group throw:
92- // / - the error thrown out of withThrowingDiscardingTaskGroup { ... } always "wins",
92+ // / - the error thrown out of withThrowingDiscardingTaskGroup(...) { ... } always "wins",
9393// / even if the group already had an error stored within.
9494// /
9595// / This is harder to implement, since we have to always store the "first error from children",
You can’t perform that action at this time.
0 commit comments