Repository: valkey-io/valkey
File: src/server.c (C)

Code before:
    dictSdsDestructor, /* key destructor */
    NULL,              /* val destructor */
    NULL,              /* allow to expand */
    .no_value = 1,     /* no values in this dict */
    .keys_are_odd = 1  /* an SDS string is always an odd pointer */
};

/* Sorted sets hash (note: a skiplist is used in addition to the hash table) */
dictType zsetDictType = {
    dictSdsHash,       /* hash function */
    NULL,              /* key dup */
    dictSdsKeyCompare, /* key compare */
    NULL,              /* Note: SDS string shared & freed by skiplist */
    NULL,              /* val destructor */
    NULL,              /* allow to expand */
};

/* Db->dict, keys are sds strings, vals are Objects. */
dictType dbDictType = {dictSdsHash,          /* hash function */
                       NULL,                 /* key dup */
                       dictSdsKeyCompare,    /* key compare */
                       NULL,                 /* key is embedded in the dictEntry and freed internally */
                       dictObjectDestructor, /* val destructor */
                       dictResizeAllowed,    /* allow to resize */
                       .embedKey = dictSdsEmbedKey,
                       .embedded_entry = 1};

/* Db->expires */
dictType dbExpiresDictType = {
    dictSdsHash,       /* hash function */
    NULL,              /* key dup */
    dictSdsKeyCompare, /* key compare */
    NULL,              /* key destructor */
    NULL,              /* val destructor */
    dictResizeAllowed, /* allow to resize */
};

/* Command table. sds string -> command struct pointer. */
dictType commandTableDictType = {
    dictSdsCaseHash,       /* hash function */
    NULL,                  /* key dup */
    dictSdsKeyCaseCompare, /* key compare */
    dictSdsDestructor,     /* key destructor */
    NULL,                  /* val destructor */
    NULL                   /* allow to expand */
};

/* Hash type hash table (note that small hashes are represented with listpacks) */
dictType hashDictType = {
    dictSdsHash,       /* hash function */
    NULL,              /* key dup */

Review comment (suggestion):
```suggestion
dictType dbDictType = {
    dictSdsHash,          /* hash function */
    NULL,                 /* key dup */
    dictSdsKeyCompare,    /* key compare */
    NULL,                 /* key is embedded in the dictEntry and freed internally */
    dictObjectDestructor, /* val destructor */
    dictResizeAllowed,    /* allow to resize */
    .embedKey = dictSdsEmbedKey,
    .embedded_entry = 1,
};
```

Apparently makes clang happy? I don't get clang.

Code after:
    dictSdsDestructor, /* key destructor */
    NULL,              /* val destructor */
    NULL,              /* allow to expand */
    .no_value = 1,     /* no values in this dict */
    .keys_are_odd = 1  /* an SDS string is always an odd pointer */
};

/* Sorted sets hash (note: a skiplist is used in addition to the hash table) */
dictType zsetDictType = {
    dictSdsHash,       /* hash function */
    NULL,              /* key dup */
    dictSdsKeyCompare, /* key compare */
    NULL,              /* Note: SDS string shared & freed by skiplist */
    NULL,              /* val destructor */
    NULL,              /* allow to expand */
};

/* Db->dict, keys are sds strings, vals are Objects. */
dictType dbDictType = {
    dictSdsHash,          /* hash function */
    NULL,                 /* key dup */
    dictSdsKeyCompare,    /* key compare */
    NULL,                 /* key is embedded in the dictEntry and freed internally */
    dictObjectDestructor, /* val destructor */
    dictResizeAllowed,    /* allow to resize */
    .embedKey = dictSdsEmbedKey,
    .embedded_entry = 1,
};

/* Db->expires */
dictType dbExpiresDictType = {
    dictSdsHash,       /* hash function */
    NULL,              /* key dup */
    dictSdsKeyCompare, /* key compare */
    NULL,              /* key destructor */
    NULL,              /* val destructor */
    dictResizeAllowed, /* allow to resize */
};

/* Command table. sds string -> command struct pointer. */
dictType commandTableDictType = {
    dictSdsCaseHash,       /* hash function */
    NULL,                  /* key dup */
    dictSdsKeyCaseCompare, /* key compare */
    dictSdsDestructor,     /* key destructor */
    NULL,                  /* val destructor */
    NULL                   /* allow to expand */
};

/* Hash type hash table (note that small hashes are represented with listpacks) */
dictType hashDictType = {