Add _erase for array

This commit is contained in:
Patrick Pelissier committed 2018-10-27 23:30:21 +02:00
1 parent bd315c7e43
commit 6672becdd5
2 files changed
+17

No files matched your search

+8
View File
@@ -175,6 +175,14 @@ static void test_uint(void)
assert (x == 1478963);
assert (s == *array_uint_back(v));
s = array_uint_size (v);
bool b = array_uint_erase (v, 12459);
assert (b == false);
assert (s == array_uint_size (v));
b = array_uint_erase (v, 0);
assert (b == true);
assert (s == array_uint_size (v)+1);
array_uint_clear(v);
array_uint_clear(v2);
}