Merge pull request #109 from akopytov/gh-108

Quiet implicit fallthrough compiler warnings.
cos
Olivier Houchard 7 years ago committed by GitHub
commit 005c715387
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -155,7 +155,9 @@ static inline void MurmurHash3_x86_32 ( const void * key, int len,
switch(len & 3)
{
case 3: k1 ^= tail[2] << 16;
/* fall through */
case 2: k1 ^= tail[1] << 8;
/* fall through */
case 1: k1 ^= tail[0];
k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1;
};
@ -204,11 +206,17 @@ static inline uint64_t MurmurHash64A ( const void * key, int len, uint64_t seed
switch(len & 7)
{
case 7: h ^= (uint64_t)(data2[6]) << 48;
/* fall through */
case 6: h ^= (uint64_t)(data2[5]) << 40;
/* fall through */
case 5: h ^= (uint64_t)(data2[4]) << 32;
/* fall through */
case 4: h ^= (uint64_t)(data2[3]) << 24;
/* fall through */
case 3: h ^= (uint64_t)(data2[2]) << 16;
/* fall through */
case 2: h ^= (uint64_t)(data2[1]) << 8;
/* fall through */
case 1: h ^= (uint64_t)(data2[0]);
h *= m;
};
@ -257,7 +265,9 @@ static inline uint64_t MurmurHash64B ( const void * key, int len, uint64_t seed
switch(len)
{
case 3: h2 ^= ((const unsigned char*)data)[2] << 16;
/* fall through */
case 2: h2 ^= ((const unsigned char*)data)[1] << 8;
/* fall through */
case 1: h2 ^= ((const unsigned char*)data)[0];
h2 *= m;
};

Loading…
Cancel
Save