rust/tests/ui/lint/must_not_suspend/unit.stderr

27 lines
695 B
Plaintext
Raw Normal View History

2021-09-15 13:48:34 -05:00
error: `Umm` held across a suspend point, but should not be
--> $DIR/unit.rs:23:9
2021-09-04 21:36:51 -05:00
|
LL | let _guard = bar();
| ^^^^^^
LL | other().await;
| ------ the value is held across this suspend point
2021-09-04 21:36:51 -05:00
|
2021-09-13 10:19:40 -05:00
note: You gotta use Umm's, ya know?
--> $DIR/unit.rs:23:9
2021-09-13 10:19:40 -05:00
|
LL | let _guard = bar();
| ^^^^^^
2021-09-15 13:48:34 -05:00
help: consider using a block (`{ ... }`) to shrink the value's scope, ending before the suspend point
--> $DIR/unit.rs:23:9
2021-09-04 21:36:51 -05:00
|
LL | let _guard = bar();
| ^^^^^^
2022-09-18 10:55:36 -05:00
note: the lint level is defined here
--> $DIR/unit.rs:6:9
2022-09-18 10:55:36 -05:00
|
LL | #![deny(must_not_suspend)]
| ^^^^^^^^^^^^^^^^
2021-09-04 21:36:51 -05:00
error: aborting due to previous error