Skip to content

Commit 8f05d12

Browse files
committed
Duplicate allocations in lowering.
1 parent 4d77382 commit 8f05d12

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/librustc/hir/lowering/item.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -1122,7 +1122,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
11221122
let stmt = this.stmt_let_pat(
11231123
stmt_attrs,
11241124
desugared_span,
1125-
Some(this.arena.alloc(expr)),
1125+
Some(expr),
11261126
parameter.pat,
11271127
hir::LocalSource::AsyncFn,
11281128
);
@@ -1152,7 +1152,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
11521152
let move_stmt = this.stmt_let_pat(
11531153
AttrVec::new(),
11541154
desugared_span,
1155-
Some(this.arena.alloc(move_expr)),
1155+
Some(move_expr),
11561156
move_pat,
11571157
hir::LocalSource::AsyncFn,
11581158
);
@@ -1163,7 +1163,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
11631163
let pattern_stmt = this.stmt_let_pat(
11641164
stmt_attrs,
11651165
desugared_span,
1166-
Some(this.arena.alloc(pattern_expr)),
1166+
Some(pattern_expr),
11671167
parameter.pat,
11681168
hir::LocalSource::AsyncFn,
11691169
);

0 commit comments

Comments
 (0)