Add method pop_until

This commit is contained in:
Patrick Pelissier committed 2018-03-14 23:46:30 +01:00
1 parent a6bf530c5f
commit 3e609bab04
1 file changed
+8
+8
View File
@@ -378,6 +378,14 @@
ARRAYI_CONTRACT(v); \
} \
\
static inline void \
M_C(name, _pop_until)(array_t v, array_it_t pos) \
{ \
ARRAYI_CONTRACT(v); \
assert (v == pos->array); \
v->size = pos->index; \
} \
\
static inline bool \
M_C(name, _empty_p)(const array_t v) \
{ \