refactor lisp runtime to use vec_t* instead of ivec_t*

bit nicer to look at, should have about the same painful performance
hit anyway.
This commit is contained in:
2025-08-20 22:43:23 +01:00
parent 6e2db6825d
commit 13142dc7f3
4 changed files with 15 additions and 23 deletions

View File

@@ -34,9 +34,9 @@ lisp_t *cons(sys_t *sys, lisp_t *car, lisp_t *cdr)
lisp_t *make_vec(sys_t *sys, u64 capacity)
{
lvec_t *lvec = calloc(1, sizeof(*lvec));
ivec_make(&lvec->data, capacity);
lisp_t *ptr = tag_vec(lvec);
vec_t *vec = calloc(1, sizeof(*vec));
vec_ensure_free(vec, MAX(capacity, VEC_DEFAULT_CAPACITY));
lisp_t *ptr = tag_vec(vec);
sys_register(sys, ptr);
return ptr;
}