提交 abf3e048 编写于 作者: S Scott Olson

Do not force_allocate Box destination.

上级 197e89bb
......@@ -635,13 +635,8 @@ fn eval_rvalue_into_lvalue(
}
Box(ty) => {
// FIXME(solson)
let dest = self.force_allocation(dest)?.to_ptr();
let size = self.type_size(ty);
let align = self.type_align(ty);
let ptr = self.memory.allocate(size, align)?;
self.memory.write_ptr(dest, ptr)?;
let ptr = self.alloc_ptr(ty)?;
self.write_primval(dest, PrimVal::Ptr(ptr))?;
}
Cast(kind, ref operand, cast_ty) => {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册