1
Fork 0

libcore: Remove ptr::mut_addr_of since &mut is coerced to *mut

This commit is contained in:
Luqman Aden 2013-02-14 19:00:04 -05:00 committed by Luqman Aden
parent af2f0ef088
commit cc89029942
7 changed files with 17 additions and 27 deletions

View file

@ -2110,7 +2110,7 @@ pub mod raw {
let v: **vec::raw::VecRepr = cast::transmute(v);
let repr: *vec::raw::VecRepr = *v;
(*repr).unboxed.fill = new_len + 1u;
let null = ptr::mut_offset(ptr::mut_addr_of(&((*repr).unboxed.data)),
let null = ptr::mut_offset(cast::transmute(&((*repr).unboxed.data)),
new_len);
*null = 0u8;
}