1 When using generators (or async) all type variables must be bound so a
2 generator can be constructed.
4 Erroneous code example:
6 ```edition2018,compile_fail,E0698
7 async fn bar<T>() -> () {}
10 bar().await; // error: cannot infer type for `T`
14 In the above example `T` is unknowable by the compiler.
15 To fix this you must bind `T` to a concrete type such as `String`
16 so that a generator can then be constructed:
19 async fn bar<T>() -> () {}
22 bar::<String>().await;
23 // ^^^^^^^^ specify type explicitly