diff options
Diffstat (limited to 'collections/vector/vector.adoc')
-rw-r--r-- | collections/vector/vector.adoc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/collections/vector/vector.adoc b/collections/vector/vector.adoc index f1e29e2..3fe2dbf 100644 --- a/collections/vector/vector.adoc +++ b/collections/vector/vector.adoc @@ -1,7 +1,7 @@ Vector ====== Tucker Evans -v0.8, 2020-07-03 +v0.8.1, 2020-07-03 A basic vector, that hold pointers to your data structures. @@ -61,7 +61,7 @@ Examples vec *vector = vec_new(); assert(vec_size(vector) == 0); -vec_push_back(vector, NULL); +vec_push(vector, NULL); assert(vec_size(vector) == 1); ---- @@ -96,12 +96,12 @@ char *str1 = "ONE"; char *str2 = "TWO"; vec *vector = vec_with_capacity(16); -vec_push_back(vector, str_dup(str1)); -vec_push_back(vector, str_dup(str2)); +vec_push(vector, str_dup(str1)); +vec_push(vector, str_dup(str2)); vec *new = vec_cp(vector); -assert(strcmp(vec_pop_back, str2) == 0); -assert(strcmp(vec_pop_back, str1) == 0); +assert(strcmp(vec_pop, str2) == 0); +assert(strcmp(vec_pop, str1) == 0); ---- [[vec_print]] @@ -229,8 +229,8 @@ char *str1 = "ONE"; char *str2 = "TWO"; vec *vector = vec_new(); -vec_push_back(vector, str_dup(str1)); -vec_push_back(vector, str_dup(str2)); +vec_push(vector, str_dup(str1)); +vec_push(vector, str_dup(str2)); vec_clear(vector); assert(vec_size(vector) == 0); |