diff options
| author | Daniel Micay <danielmicay@gmail.com> | 2013-10-07 17:18:10 -0400 |
|---|---|---|
| committer | Daniel Micay <danielmicay@gmail.com> | 2013-10-07 17:18:10 -0400 |
| commit | a9fb88d4f8c44daadce81fbd009ff4676a38d5e9 (patch) | |
| tree | ddb2672879b7192af846866657c64b7e7d4fc708 | |
| parent | 8eb28bb7dcd77ac9e804ab2d75b387ca3f47f9d4 (diff) | |
rm special case for ty_struct from take glue
This is incorrect, as take glue isn't used for moves.
| -rw-r--r-- | src/librustc/middle/trans/glue.rs | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/src/librustc/middle/trans/glue.rs b/src/librustc/middle/trans/glue.rs index d420514e84f..eafbb0e9d01 100644 --- a/src/librustc/middle/trans/glue.rs +++ b/src/librustc/middle/trans/glue.rs @@ -595,23 +595,6 @@ pub fn make_take_glue(bcx: @mut Block, v: ValueRef, t: ty::t) -> @mut Block { bcx } ty::ty_opaque_closure_ptr(_) => bcx, - ty::ty_struct(did, _) => { - let tcx = bcx.tcx(); - let bcx = iter_structural_ty(bcx, v, t, take_ty); - - match ty::ty_dtor(tcx, did) { - ty::TraitDtor(_, false) => { - // Zero out the struct - unsafe { - let ty = Type::from_ref(llvm::LLVMTypeOf(v)); - memzero(&B(bcx), v, ty); - } - - } - _ => { } - } - bcx - } _ if ty::type_is_structural(t) => { iter_structural_ty(bcx, v, t, take_ty) } |
