Removing the "uint8*" methods from SerializationFormat.

They conflict with the "char" version, so that other classes would now
pick the wrong one. Added a bit of casting to HLL to use the "char"
versions instead.
This commit is contained in:
Robin Sommer 2013-08-31 11:03:40 -07:00
parent a8ac7d8a5b
commit de5bb65ff7
4 changed files with 4 additions and 38 deletions

View file

@ -161,7 +161,7 @@ bool CardinalityCounter::Serialize(SerialInfo* info) const
valid &= SERIALIZE(alpha_m);
for ( unsigned int i = 0; i < m; i++ )
valid &= SERIALIZE(buckets[i]);
valid &= SERIALIZE((char)buckets[i]);
return valid;
}
@ -183,8 +183,9 @@ CardinalityCounter* CardinalityCounter::Unserialize(UnserialInfo* info)
for ( unsigned int i = 0; i < m; i++ )
{
uint8_t* currbucket = buckets + i;
valid &= UNSERIALIZE(currbucket);
char c;
valid &= UNSERIALIZE(&c);
buckets[i] = (uint8)c;
}
return valid ? c : 0;