Skip to content
Myr

fix PR to work on VC6

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Sean Barrett · committed by Sean Barrett · parent 206529e · Browse files · 1 file+1 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−2 removed

  • other:+1 added−2 removed

1 file+1 added−2 removed

modified:stb_ds.h+1 added-2 removed
831 unmodified lines
832#define STBDS_SIZE_T_BITS ((sizeof (size_t)) * 8)833834static size_t stbds_probe_position(size_t hash, size_t slot_count, size_t slot_log2)835{836 STBDS_NOTUSED(slot_log2);836 size_t pos;837 STBDS_NOTUSED(slot_log2);838 pos = hash & (slot_count-1);839 #ifdef STBDS_INTERNAL_BUCKET_START840 pos &= ~STBDS_BUCKET_MASK;841 #endif
330 unmodified lines
117211731174static int stbds_is_key_equal(void *a, size_t elemsize, void *key, size_t keysize, size_t keyoffset, int mode, size_t i)1175{1176 STBDS_NOTUSED(keyoffset);1176 if (mode >= STBDS_HM_STRING)1177 return 0==strcmp((char *) key, * (char **) ((char *) a + elemsize*i + keyoffset));1178 else1179 return 0==memcmp(key, (char *) a + elemsize*i + keyoffset, keysize);
656 unmodified lines