B+TREE: Add _pop function.

This commit is contained in:
Patrick Pelissier committed 2018-04-04 22:39:46 +02:00
1 parent c91864c2a7
commit 7ca254ade9
1 file changed
+11
+11
View File
@@ -530,5 +530,16 @@
} \
} \
\
static inline bool M_C(name, _pop)(value_t *ptr, tree_t b, key_t const key) \
{ \
if (ptr != NULL) { \
value_t *ref = M_C(name, _get)(b, key); \
if (ref == NULL) { \
return false; \
} \
M_GET_SET value_oplist (*ptr, *ref); \
} \
return M_C(name, _remove)(b, key); \
} \
#endif