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

Function createSortOperation

src/sort.cpp:38–43  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36zskiplistNode* zslGetElementByRank(zskiplist *zsl, unsigned long rank);
37
38redisSortOperation *createSortOperation(int type, robj *pattern) {
39 redisSortOperation *so = (redisSortOperation*)zmalloc(sizeof(*so), MALLOC_LOCAL);
40 so->type = type;
41 so->pattern = pattern;
42 return so;
43}
44
45/* Return the value associated to the key with a name obtained using
46 * the following rules:

Callers 1

sortCommandFunction · 0.85

Calls 1

zmallocFunction · 0.85

Tested by

no test coverage detected