Divide vec fill by element size when reporting vec len.

This commit is contained in:
Graydon Hoare 2010-07-05 14:40:01 -07:00
parent 0fe1508a8a
commit fdf2eaac91
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ vec_buf(rust_task *task, type_desc *ty, rust_vec *v)
extern "C" CDECL size_t
vec_len(rust_task *task, type_desc *ty, rust_vec *v)
{
return v->fill;
return v->fill / ty->size;
}
//