We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e2f078e commit f96567cCopy full SHA for f96567c
docs/async-await.md
@@ -150,7 +150,7 @@ extension HTTPClient {
150
let response = try await httpClient.execute(request, deadline: .distantFuture)
151
}
152
153
- Task.sleep(500 * 1000 * 1000) // wait half a second
+ await Task.sleep(nanosecond: 500 * 1000 * 1000) // wait half a second
154
task.cancel() // cancel the task after half a second
155
```
156
0 commit comments