diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2012-09-26 17:33:34 -0700 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2012-09-26 18:02:07 -0700 |
| commit | 67a8e7128aea292445b763b47b04bc5f4fd43cb2 (patch) | |
| tree | 9ddde322dbc8fd5af39e903419cae508d9df05f6 /src/libcore/run.rs | |
| parent | cd79e1d1b20a2c289dd15bc2766f97c789d975aa (diff) | |
| download | rust-67a8e7128aea292445b763b47b04bc5f4fd43cb2.tar.gz rust-67a8e7128aea292445b763b47b04bc5f4fd43cb2.zip | |
Demode vec::push (and convert to method)
Diffstat (limited to 'src/libcore/run.rs')
| -rw-r--r-- | src/libcore/run.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/libcore/run.rs b/src/libcore/run.rs index e3e8491e15a..abeff1bd1d6 100644 --- a/src/libcore/run.rs +++ b/src/libcore/run.rs @@ -82,10 +82,10 @@ fn with_argv<T>(prog: &str, args: &[~str], let mut tmps = ~[]; for vec::each(args) |arg| { let t = @copy *arg; - vec::push(tmps, t); - vec::push_all(argptrs, str::as_c_str(*t, |b| ~[b])); + tmps.push(t); + argptrs.push_all(str::as_c_str(*t, |b| ~[b])); } - vec::push(argptrs, ptr::null()); + argptrs.push(ptr::null()); vec::as_imm_buf(argptrs, |buf, _len| cb(buf)) } @@ -102,10 +102,10 @@ fn with_envp<T>(env: &Option<~[(~str,~str)]>, for vec::each(es) |e| { let (k,v) = copy *e; let t = @(fmt!("%s=%s", k, v)); - vec::push(tmps, t); - vec::push_all(ptrs, str::as_c_str(*t, |b| ~[b])); + tmps.push(t); + ptrs.push_all(str::as_c_str(*t, |b| ~[b])); } - vec::push(ptrs, ptr::null()); + ptrs.push(ptr::null()); vec::as_imm_buf(ptrs, |p, _len| unsafe { cb(::cast::reinterpret_cast(&p)) } ) |
