stdlib: Replace an unsafe cast with ptr::null

This commit is contained in:
Brian Anderson 2011-10-28 14:25:40 -07:00
parent f96ad30dfc
commit 54ddb553c2

View File

@ -92,8 +92,7 @@ type program = obj {
fn arg_vec(prog: str, args: [@str]) -> [sbuf] {
let argptrs = str::as_buf(prog, {|buf| [buf] });
for arg in args { argptrs += str::as_buf(*arg, {|buf| [buf] }); }
// FIXME: ptr::null instead of cast
argptrs += [unsafe {unsafe::reinterpret_cast(0)}];
argptrs += [ptr::null()];
ret argptrs;
}