Go to the documentation of this file.
99 #define csnip_lphash_Find( \
118 (return_state) = 2; \
124 size_t u = (hash) % (N); \
128 (return_state) = 0; \
129 while (!(is_empty) && !(is_match)) \
136 (return_state) = 2; \
142 (return_state) = 1; \
176 #define csnip_lphash_Findnext( \
191 size_t u = (loc_prev); \
201 } while(!(is_empty) && !(is_match)); \
228 #define csnip_lphash_Delete( \
246 if ((is_empty) || u == v) { \
252 keytype k = (get_key); \
253 size_t h = (hash) % (N); \
254 if (v - h < u - h) { \
279 #define csnip_lphash_Nextentry( \
287 while ((is_empty) && u < (N)) { \
298 #define CSNIP_LPHASH_DECL_FUNCS(scope, prefix, keytype, argl) \
299 scope size_t prefix ## findloc(csnip_pp_prepend_##argl \
300 keytype key, int* state); \
301 scope size_t prefix ## findnextloc(csnip_pp_prepend_##argl keytype key, size_t loc); \
302 scope void prefix ## deleteloc(csnip_pp_prepend_##argl size_t loc); \
303 scope size_t prefix ## nextentry(csnip_pp_prepend_##argl size_t loc);
317 #define CSNIP_LPHASH_DEF_FUNCS(scope, prefix, \
328 scope size_t prefix##findloc( \
329 csnip_pp_prepend_##argl \
334 csnip_lphash_Find(N, keytype, k, u, hash, is_empty, is_match, \
335 get_key, key, ret_, *state_); \
339 scope size_t prefix ## findnextloc( \
340 csnip_pp_prepend_##argl \
346 csnip_lphash_Findnext(N, keytype, k, u, hash, is_empty, \
347 is_match, get_key, key, loc, ret_, *state_); \
351 scope void prefix ## deleteloc(csnip_pp_prepend_##argl size_t loc) \
353 csnip_lphash_Delete(N, keytype, k, u, v, hash, is_empty, \
354 get_key, copy, clear, loc); \
357 scope size_t prefix ## nextentry(csnip_pp_prepend_##argl size_t loc) \
359 csnip_lphash_Nextentry(N, u, is_empty, loc, loc); \