diff --git a/dynarray.c b/dynarray.c index e141f52..f892af0 100644 --- a/dynarray.c +++ b/dynarray.c @@ -75,7 +75,7 @@ enum { // Avoid collision in error numbers }; // Present a unified structure that may receive changes, deprecations and renames without hassle for external users -const struct corelibs_dynarray_interface dynarray = { +const struct corelibs_dynarray_interface cl_dynarray = { .make = { .new = corelibs_dynarray_make_new, .slice = corelibs_dynarray_make_slice, @@ -325,7 +325,7 @@ corelibs_dynarray_mod_ct_rep(cl_dynarray_t* arr, uintmax_t pos, uintmax_t cnt, c goto ret; } - if (corelibs_dynarray_bcheck(arr, pos, cnt) == dynarray.err.mem.oob) { + if (corelibs_dynarray_bcheck(arr, pos, cnt) == CORELIBS_DYNARRAY_ERR_MEM_OOB) { // Resize array to fit new elements if ((err = corelibs_dynarray_mod_arr_cap(arr, pos + cnt)) != CORELIBS_DYNARRAY_ERR_OK) goto ret; } diff --git a/dynarray.h b/dynarray.h index bd566e4..c533a75 100644 --- a/dynarray.h +++ b/dynarray.h @@ -103,7 +103,7 @@ struct corelibs_dynarray_interface { } err; }; -extern const struct corelibs_dynarray_interface dynarray; +extern const struct corelibs_dynarray_interface cl_dynarray; #endif /* CORELIBS_GUARD_DYNARRAY */