mirror of
https://github.com/msgpack/msgpack-c.git
synced 2025-03-19 13:02:13 +01:00
Fixed dereferencing type-punned pointer will break strict-aliasing rules warning.
This commit is contained in:
parent
cb518f472a
commit
12e8615ac5
@ -843,9 +843,11 @@ public:
|
||||
TestEnumType t2;
|
||||
TestEnumType t3;
|
||||
|
||||
MSGPACK_DEFINE((int&)t1, (int&)t2, (int&)t3);
|
||||
MSGPACK_DEFINE(t1, t2, t3);
|
||||
};
|
||||
|
||||
MSGPACK_ADD_ENUM(TestEnumMemberClass::TestEnumType);
|
||||
|
||||
TEST(MSGPACK_USER_DEFINED, simple_buffer_enum_member)
|
||||
{
|
||||
TestEnumMemberClass val1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user