MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / intsetGet

Function intsetGet

src/intset.c:270–276  ·  view source on GitHub ↗

Get the value at the given position. When this position is * out of range the function returns 0, when in range it returns 1. */

Source from the content-addressed store, hash-verified

268/* Get the value at the given position. When this position is
269 * out of range the function returns 0, when in range it returns 1. */
270uint8_t intsetGet(intset *is, uint32_t pos, int64_t *value) {
271 if (pos < intrev32ifbe(is->length)) {
272 *value = _intsetGet(is,pos);
273 return 1;
274 }
275 return 0;
276}
277
278/* Return intset length */
279uint32_t intsetLen(const intset *is) {

Callers 5

scanGenericCommandFunction · 0.85
zuiNextFunction · 0.85
setTypeNextFunction · 0.85
RM_ScanKeyFunction · 0.85
rewriteSetObjectFunction · 0.85

Calls 1

_intsetGetFunction · 0.85

Tested by

no test coverage detected