rust/tests/ui/async-await/no-non-guaranteed-initialization.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

17 lines
572 B
Plaintext
Raw Normal View History

2022-06-22 13:04:36 -05:00
error[E0381]: used binding `y` is possibly-uninitialized
--> $DIR/no-non-guaranteed-initialization.rs:9:5
|
LL | let y;
2022-06-21 17:54:17 -05:00
| - binding declared here but left uninitialized
LL | if x > 5 {
2022-06-22 13:04:36 -05:00
| ----- if this `if` condition is `false`, `y` is not initialized
LL | y = echo(10).await;
LL | }
| - an `else` arm might be missing here, initializing `y`
LL | y
2022-06-22 13:04:36 -05:00
| ^ `y` used here but it is possibly-uninitialized
error: aborting due to previous error
For more information about this error, try `rustc --explain E0381`.