Skip to content

Commit 07125aa

Browse files
committed
Fix bug that prevented boxes-in-resources from being freed
1 parent e2cb97a commit 07125aa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/comp/middle/trans.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2138,7 +2138,7 @@ fn drop_res(@block_ctxt cx, ValueRef rs, ty::t inner_t, &ast::_fn dtor)
21382138
cx = val.bcx;
21392139
cx.fcx.llargs.insert(dtor.decl.inputs.(0).id, val.val);
21402140
cx = trans_block(cx, dtor.body, return).bcx;
2141-
cx = drop_ty(cx, val.val, inner_t).bcx;
2141+
cx = drop_slot(cx, val.val, inner_t).bcx;
21422142
cx.build.Store(C_int(0), drop_flag.val);
21432143
cx.build.Br(next_cx.llbb);
21442144

0 commit comments

Comments
 (0)