Rewrite everything to use [] instead of vec() in value position.

This commit is contained in:
Graydon Hoare
2011-05-16 18:21:22 -07:00
parent ae030c5bf2
commit fbbc1a77d2
87 changed files with 1137 additions and 1134 deletions

View File

@@ -65,7 +65,7 @@ fn dylib_filename(str base) -> str {
}
fn pipe() -> tup(int, int) {
let vec[mutable int] fds = vec(mutable 0, 0);
let vec[mutable int] fds = [mutable 0, 0];
assert (os::libc::pipe(_vec::buf(fds)) == 0);
ret tup(fds.(0), fds.(1));
}
@@ -75,7 +75,7 @@ fn fd_FILE(int fd) -> libc::FILE {
}
fn waitpid(int pid) -> int {
let vec[mutable int] status = vec(mutable 0);
let vec[mutable int] status = [mutable 0];
assert (os::libc::waitpid(pid, _vec::buf(status), 0) != -1);
ret status.(0);
}