B+TREE: Add _pop function.
This commit is contained in:
1 parent
c91864c2a7
commit
7ca254ade9
1 file changed
+11
+11
@@ -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
|
||||
Reference in new issue
Block a user