Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add try await keywords when chopping veggies #44

Open
wants to merge 1 commit into
base: structured-concurrency
Choose a base branch
from

Conversation

ryansobol
Copy link

Is this code example missing the try await keywords when chopping veggies? In the previous example, inside the loop that would not produce any meaningful concurrency, line 190 is written:

veggies[i] = try await veggies[i].chopped()

It seems like the chopped() method has the potential for an async kitchen knife incident for each veggie. I assume this potential also needs to be accounted for in the meaningful concurrency example too?

Is this code example missing the `try await` keywords when chopping veggies? In the previous example, inside the loop that would not produce any meaningful concurrency, line 190 is written:

```swift
veggies[i] = try await veggies[i].chopped()
```

It seems like the `chopped()` method  has the potential for a kitchen knife incident for each veggie. I assume this needs to be accounted for in the meaningful concurrency example too?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant