: public TVirtualProtocol< TCompactProtocolT<Transport_> > {
protected:
- static const int8_t PROTOCOL_ID = 0x82;
+ static const int8_t PROTOCOL_ID = (int8_t)0x82;
static const int8_t VERSION_N = 1;
static const int8_t VERSION_MASK = 0x1f; // 0001 1111
- static const int8_t TYPE_MASK = 0xE0; // 1110 0000
+ static const int8_t TYPE_MASK = (int8_t)0xE0; // 1110 0000
static const int32_t TYPE_SHIFT_AMOUNT = 5;
Transport_* trans_;
OneOfEach ooe;
ooe.im_true = true;
ooe.im_false = false;
- ooe.a_bite = 0xd6;
+ ooe.a_bite = 0x7f;
ooe.integer16 = 27000;
ooe.integer32 = 1<<24;
ooe.integer64 = (uint64_t)6000 * 1000 * 1000;
OneOfEach ooe;
ooe.im_true = true;
ooe.im_false = false;
- ooe.a_bite = 0xd6;
+ ooe.a_bite = 0x7f;
ooe.integer16 = 27000;
ooe.integer32 = 1<<24;
ooe.integer64 = (uint64_t)6000 * 1000 * 1000;
OneOfEach ooe;
ooe.im_true = true;
ooe.im_false = false;
- ooe.a_bite = 0xd6;
+ ooe.a_bite = 0x7f;
ooe.integer16 = 27000;
ooe.integer32 = 1<<24;
ooe.integer64 = (uint64_t)6000 * 1000 * 1000;
assert(hm == hm2);
- hm2.big[0].a_bite = 0xFF;
+ hm2.big[0].a_bite = 0x00;
assert(hm != hm2);
OneOfEach ooe;
ooe.im_true = true;
ooe.im_false = false;
- ooe.a_bite = 0xd6;
+ ooe.a_bite = 0x7f;
ooe.integer16 = 27000;
ooe.integer32 = 1<<24;
ooe.integer64 = (uint64_t)6000 * 1000 * 1000;
assert(hm == hm2);
- hm2.big[0].a_bite = 0xFF;
+ hm2.big[0].a_bite = 0x00;
assert(hm != hm2);
struct OneOfEach {
1: bool im_true,
2: bool im_false,
- 3: byte a_bite = 200,
- 4: i16 integer16 = 33000,
+ 3: byte a_bite = 0x7f,
+ 4: i16 integer16 = 0x7fff,
5: i32 integer32,
6: i64 integer64 = 10000000000,
7: double double_precision,