I tried to complied the following reqwest example:
let client = reqwest::Client::new();
let res = client.post("http://httpbin.org/post")
    .body("the exact body that is sent")
    .send()?;
The example fails to compile:
error[E0277]: the `?` operator can only be applied to values that implement `std::ops::Try`
  --> src/main.rs:26:15
   |
26 |       let res = client.post("http://httpbin.org/post")
   |  _______________^
27 | |     .body("the exact body that is sent")
28 | |     .send()?;
   | |____________^ the `?` operator cannot be applied to type `impl std::future::Future`
   |
   = help: the trait `std::ops::Try` is not implemented for `impl std::future::Future`
   = note: required by `std::ops::Try::into_result`
error[E0277]: the `?` operator can only be used in a function that returns `Result` or `Option` (or another type that implements `std::ops::Try`)
  --> src/main.rs:26:15
   |
11 |  / fn main(){
12 |  |     // gets the api key from env var
13 |  |     let mut key: String = env::var("key").unwrap();
14 |  |     // get the mok key bassically useless but its still useful to prevent tampering
...   |
26 |  |     let res = client.post("http://httpbin.org/post")
   |  |_______________^
27 | ||     .body("the exact body that is sent")
28 | ||     .send()?;
   | ||____________^ cannot use the `?` operator in a function that returns `()`
...   |
49 |  |     //}
50 |  | }
   |  |_- this function should return `Result` or `Option` to accept `?`
   |
   = help: the trait `std::ops::Try` is not implemented for `()`
   = note: required by `std::ops::Try::from_error`
How should I fix this? Is this out of date? I am using Rust version 1.47.0
 
     
    