diff options
| author | Simonas Kazlauskas <git@kazlauskas.me> | 2016-02-07 21:47:23 +0200 |
|---|---|---|
| committer | Simonas Kazlauskas <git@kazlauskas.me> | 2016-02-07 21:47:23 +0200 |
| commit | ae151d3945e715b7c61ef7b7e5628b915ea320b7 (patch) | |
| tree | ff5ce993ccb33bf4f3d318406f456fa612aac9dd | |
| parent | f50fb159e97eee82b4ff6abaa4003a49d6fe680f (diff) | |
| download | rust-ae151d3945e715b7c61ef7b7e5628b915ea320b7.tar.gz rust-ae151d3945e715b7c61ef7b7e5628b915ea320b7.zip | |
[MIR] Fix the destination of implicit else branch
| -rw-r--r-- | src/librustc_mir/build/expr/into.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_mir/build/expr/into.rs b/src/librustc_mir/build/expr/into.rs index f50e5689df0..ca00b99b108 100644 --- a/src/librustc_mir/build/expr/into.rs +++ b/src/librustc_mir/build/expr/into.rs @@ -63,7 +63,7 @@ impl<'a,'tcx> Builder<'a,'tcx> { } else { // Body of the `if` expression without an `else` clause must return `()`, thus // we implicitly generate a `else {}` if it is not specified. - this.cfg.push_assign_unit(else_block, expr_span, &Lvalue::ReturnPointer); + this.cfg.push_assign_unit(else_block, expr_span, destination); else_block }; |
