Skip to content

Commit

Permalink
Revert "Add flag in build as_rvalue"
Browse files Browse the repository at this point in the history
This reverts commit a313dba20f1449f227e2fe0be20b7c48fd4de13b.
  • Loading branch information
pierwill committed Jul 13, 2022
1 parent 335315a commit bca3928
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions compiler/rustc_mir_build/src/build/expr/as_rvalue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -601,9 +601,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
let this = self;

let source_info = this.source_info(upvar_span);
let mut decl = LocalDecl::new(upvar_ty, upvar_span);
decl.always_storage_live = true; // this will be StorageLive below
let temp = this.local_decls.push(decl);
let temp = this.local_decls.push(LocalDecl::new(upvar_ty, upvar_span));

this.cfg.push(block, Statement { source_info, kind: StatementKind::StorageLive(temp) });

Expand Down

0 comments on commit bca3928

Please sign in to comment.