feature: Added structure for ArrayListSlices
This commit is contained in:
@@ -7,15 +7,7 @@
|
||||
|
||||
typedef struct ArrayList ArrayList;
|
||||
|
||||
// FUCK, i forgot one of the main reasons i wanted to
|
||||
// implement arrays myself was because i needed
|
||||
// array slices or something like this and i completely
|
||||
// forgot, fuck, guess i will implement it once i get
|
||||
// the tests done.
|
||||
typedef struct {
|
||||
ArrayList *array;
|
||||
size_t offset;
|
||||
} ArrayListSlice;
|
||||
typedef struct ArrayListSlice ArrayListSlice;
|
||||
|
||||
typedef enum {
|
||||
ARRLIST_OK = 0,
|
||||
@@ -26,6 +18,7 @@ typedef enum {
|
||||
ARRLIST_NULL_ARG,
|
||||
ARRLIST_INVALID_ELEM_SIZE,
|
||||
ARRLIST_INVALID_CAPACITY,
|
||||
ARRLIST_IS_BORROWED,
|
||||
} ArrayListErr;
|
||||
|
||||
ArrayList *arraylist_init(size_t capacity, size_t elem_size);
|
||||
|
||||
Reference in New Issue
Block a user