File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
stdlib/public/Concurrency Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -416,20 +416,20 @@ extension DiscardingTaskGroup: Sendable { }
416416///
417417/// Generally, this suits the typical use-cases of a
418418/// discarding task group well, however, if you wanted to prevent specific
419- /// errors from cancelling the group one should catch them inside the child
419+ /// errors from cancelling the group one should catch them inside the child
420420/// task's body like this:
421421///
422422/// ```
423423/// try await withThrowingDiscardingTaskGroup { group in
424- /// group.addTask {
424+ /// group.addTask {
425425/// do {
426426/// try boom(1)
427427/// } catch is HarmlessError {
428428/// return
429429/// }
430430/// }
431- /// group.addTask {
432- /// try boom(2, after: .seconds(5))
431+ /// group.addTask {
432+ /// try boom(2, after: .seconds(5))
433433/// }
434434/// }
435435/// ```
You can’t perform that action at this time.
0 commit comments