Add differently-typed refcount synonyms to _str and _vec.

This commit is contained in:
Graydon Hoare 2010-07-13 14:23:49 -07:00
parent 5063f0db96
commit 40d6aacb82
2 changed files with 2 additions and 0 deletions

View File

@ -5,6 +5,7 @@ native "rust" mod rustrt {
fn str_buf(str s) -> sbuf;
fn str_len(str s) -> uint;
fn str_alloc(uint n_bytes) -> str;
fn refcount[T](str s) -> uint;
}
fn is_utf8(vec[u8] v) -> bool {

View File

@ -6,6 +6,7 @@ native "rust" mod rustrt {
fn vec_buf[T](vec[T] v) -> vbuf;
fn vec_len[T](vec[T] v) -> uint;
fn vec_alloc[T](uint n_elts) -> vec[T];
fn refcount[T](vec[T] v) -> uint;
}
fn alloc[T](uint n_elts) -> vec[T] {