Skip to content

Commit bb482eb

Browse files
suspend -> yield
1 parent 759526e commit bb482eb

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

src/librustc/mir/mod.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -1475,9 +1475,7 @@ impl<'tcx> TerminatorKind<'tcx> {
14751475
GeneratorDrop => write!(fmt, "generator_drop"),
14761476
Resume => write!(fmt, "resume"),
14771477
Abort => write!(fmt, "abort"),
1478-
Yield { value, resume_arg, .. } => {
1479-
write!(fmt, "{:?} = suspend({:?})", resume_arg, value)
1480-
}
1478+
Yield { value, resume_arg, .. } => write!(fmt, "{:?} = yield({:?})", resume_arg, value),
14811479
Unreachable => write!(fmt, "unreachable"),
14821480
Drop { location, .. } => write!(fmt, "drop({:?})", location),
14831481
DropAndReplace { location, value, .. } => {

src/test/mir-opt/generator-storage-dead-unwind.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ fn main() {
4949
// StorageLive(_4);
5050
// _4 = Bar(const 6i32,);
5151
// ...
52-
// _5 = suspend(move _6) -> [resume: bb2, drop: bb4];
52+
// _5 = yield(move _6) -> [resume: bb2, drop: bb4];
5353
// }
5454
// bb1 (cleanup): {
5555
// resume;

0 commit comments

Comments
 (0)