diff options
| author | Roy Frostig <rfrostig@mozilla.com> | 2010-08-04 12:59:48 -0700 |
|---|---|---|
| committer | Roy Frostig <rfrostig@mozilla.com> | 2010-08-04 12:59:48 -0700 |
| commit | 1a8d609e89ed647204b68bfe40e83357644476cb (patch) | |
| tree | b72f13c7d160f5d29be6261e09c51990a3b18f01 /src/rt/rust_builtin.cpp | |
| parent | b9075c23c0c1d87296b338869bce37ca709cbce2 (diff) | |
| download | rust-1a8d609e89ed647204b68bfe40e83357644476cb.tar.gz rust-1a8d609e89ed647204b68bfe40e83357644476cb.zip | |
Add a buffered writer to stdlib _io module.
Diffstat (limited to 'src/rt/rust_builtin.cpp')
| -rw-r--r-- | src/rt/rust_builtin.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rt/rust_builtin.cpp b/src/rt/rust_builtin.cpp index 0879681c87d..657109c6df2 100644 --- a/src/rt/rust_builtin.cpp +++ b/src/rt/rust_builtin.cpp @@ -116,9 +116,9 @@ str_buf(rust_task *task, rust_str *s) } extern "C" CDECL void * -vec_buf(rust_task *task, type_desc *ty, rust_vec *v) +vec_buf(rust_task *task, type_desc *ty, rust_vec *v, size_t offset) { - return (void *)&v->data[0]; + return (void *)&v->data[ty->size * offset]; } extern "C" CDECL size_t |
