summaryrefslogtreecommitdiffstats
path: root/src/vector.h
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-08-22 17:47:51 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-08-22 17:47:51 +0200
commitad4999488eadac3a10de99caf50b732af8b771b9 (patch)
treed3ffbbc2830b4bf2b520ae6b734d1c188d465be9 /src/vector.h
parent35a18b1dea21f006b38694dcf5c99f817411ad4d (diff)
downloadfastd-ad4999488eadac3a10de99caf50b732af8b771b9.tar
fastd-ad4999488eadac3a10de99caf50b732af8b771b9.zip
Remove VECTOR_ALLOC
It is done automatically now if the VECTOR is zeroed before.
Diffstat (limited to 'src/vector.h')
-rw-r--r--src/vector.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/src/vector.h b/src/vector.h
index 0571d4d..8b60f4a 100644
--- a/src/vector.h
+++ b/src/vector.h
@@ -55,23 +55,12 @@ typedef struct fastd_vector_desc {
-void _fastd_vector_alloc(fastd_vector_desc_t *desc, void **data, size_t n, size_t elemsize);
void _fastd_vector_resize(fastd_vector_desc_t *desc, void **data, size_t n, size_t elemsize);
void _fastd_vector_insert(fastd_vector_desc_t *desc, void **data, void *element, size_t pos, size_t elemsize);
void _fastd_vector_delete(fastd_vector_desc_t *desc, void **data, size_t pos, size_t elemsize);
/**
- Allocates resources for the vector \e a, starting with \e n elements
-
- \hideinitializer
-*/
-#define VECTOR_ALLOC(v, n) ({ \
- __typeof__(v) *_v = &(v); \
- _fastd_vector_alloc(&_v->desc, (void**)&_v->data, (n), sizeof(*_v->data)); \
- })
-
-/**
Resizes the vector \e a to \e n elements
\hideinitializer