Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions proposals/nnnn-structured-concurrency.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,12 @@ Our approach follows the principles of *structured concurrency* described above.
This proposal introduces an easy way to create child tasks with `async let`:

```swift
func chopVegetables() async throws -> [Vegetable] { ... }
func marinateMeat() async -> Meat { ... }
func preheatOven(temperature: Double) async throws -> Oven { ... }

// ...

func makeDinner() async throws -> Meal {
async let veggies = chopVegetables()
async let meat = marinateMeat()
Expand Down