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.
2 parents 7f9dae9 + f57e314 commit 96b821bCopy full SHA for 96b821b
docs/src/concepts/tasks.md
@@ -17,7 +17,7 @@ async fn read_file(path: &str) -> Result<String, io::Error> {
17
18
fn main() {
19
let reader_task = task::spawn(async {
20
- let result = read_file("data.csv");
+ let result = read_file("data.csv").await;
21
match result {
22
Ok(s) => println!("{}", s),
23
Err(e) => println!("Error reading file: {:?}", e)
@@ -33,7 +33,7 @@ This asks the runtime baked into `async_std` to execute the code that reads a fi
33
34
```rust
35
async {
36
37
38
39
0 commit comments