rust/src/test/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.

15 lines
501 B
Plaintext
Raw Normal View History

2022-06-21 22:54:17 +00:00
error[E0381]: used binding `y` isn't initialized in all conditions
--> $DIR/no-non-guaranteed-initialization.rs:9:5
|
LL | let y;
2022-06-21 22:54:17 +00:00
| - binding declared here but left uninitialized
LL | if x > 5 {
2022-06-21 22:54:17 +00:00
| ----- this `if` expression might be missing an `else` arm that initializes `y`
...
LL | y
| ^ `y` used here but it isn't initialized in all conditions
error: aborting due to previous error
For more information about this error, try `rustc --explain E0381`.