Skip to content

Commit c107285

Browse files
authored
[SE-0304] Structured concurrency: fix typo (#1787)
1 parent 138fce8 commit c107285

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

proposals/0304-structured-concurrency.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1083,7 +1083,7 @@ This waiting can be performed either:
10831083
- by the code within the task group itself (e.g., using `next()` repeatedly until it returns `nil`, described below), or
10841084
- implicitly in the task group itself when returning from the `body`.
10851085

1086-
By default, the task group will schedule child tasks added to the group on the default global concurrent executor. In the future is is likely that it will be possible to customize the executor tasks are started on with an optional executor parameter to `addTask`.
1086+
By default, the task group will schedule child tasks added to the group on the default global concurrent executor. In the future it is likely that it will be possible to customize the executor tasks are started on with an optional executor parameter to `addTask`.
10871087

10881088
##### Creating TaskGroup child tasks
10891089

@@ -1135,7 +1135,7 @@ extension ThrowingTaskGroup {
11351135

11361136
The `addTask` operation always succeeds in adding a new child task to the group, even if the task running the group has been cancelled or the group was cancelled explicitly with `group.cancelAll`. In cases where the task group has already
11371137
been cancelled, the new child task will be created in the `cancelled` state.
1138-
To avoid this, the `saddTaskUnlessCancelled` function checks if a group is cancelled before attempting to create the task, and returns a `Bool` that is true if
1138+
To avoid this, the `addTaskUnlessCancelled` function checks if a group is cancelled before attempting to create the task, and returns a `Bool` that is true if
11391139
the task was successfully created. This allows for simple implementation of groups which should "keep creating tasks until cancelled".
11401140

11411141
Cancelling a specific task group child task does _not_ cancel the entire group or any of its siblings.

0 commit comments

Comments
 (0)