mirror of
https://github.com/msgpack/msgpack-c.git
synced 2025-10-17 03:03:24 +02:00
Re-designed user types dispatching mechanism.
msgpakc-c 0.5.9 or older uses ADL. msgpack-c 1.0.x uses overloading with header files ordering. msgpack-c 1.1.x uses functor with class template specialization.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
#include <msgpack_fwd.hpp>
|
||||
#include <msgpack.hpp>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
class enum_member {
|
||||
@@ -17,8 +17,6 @@ public:
|
||||
|
||||
MSGPACK_ADD_ENUM(enum_member::flags_t);
|
||||
|
||||
#include <msgpack.hpp>
|
||||
|
||||
class compatibility {
|
||||
public:
|
||||
compatibility() : str1("default"), str2("default") { }
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#include <msgpack_fwd.hpp>
|
||||
#include <msgpack.hpp>
|
||||
|
||||
#include <cmath>
|
||||
#include <string>
|
||||
@@ -38,8 +38,6 @@ public:
|
||||
|
||||
MSGPACK_ADD_ENUM(TestEnumMemberClass::TestEnumType);
|
||||
|
||||
#include <msgpack.hpp>
|
||||
|
||||
using namespace std;
|
||||
|
||||
const unsigned int kLoop = 1000;
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#include <msgpack_fwd.hpp>
|
||||
#include <msgpack.hpp>
|
||||
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
@@ -29,8 +29,6 @@ public:
|
||||
|
||||
MSGPACK_ADD_ENUM(TestEnumClassMemberClass::TestEnumClassType);
|
||||
|
||||
#include <msgpack.hpp>
|
||||
|
||||
using namespace std;
|
||||
|
||||
const unsigned int kLoop = 10000;
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#include <msgpack_fwd.hpp>
|
||||
#include <msgpack.hpp>
|
||||
#include <gtest/gtest.h>
|
||||
|
||||
|
||||
@@ -34,10 +34,6 @@ MSGPACK_ADD_ENUM(outer_enum_class::enum_class_test);
|
||||
|
||||
#endif // !defined(MSGPACK_USE_CPP03)
|
||||
|
||||
|
||||
|
||||
#include <msgpack.hpp>
|
||||
|
||||
struct myclass {
|
||||
myclass() : num(0), str("default") { }
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#include <msgpack_fwd.hpp>
|
||||
#include <msgpack.hpp>
|
||||
#include <gtest/gtest.h>
|
||||
#include <cmath>
|
||||
|
||||
@@ -40,9 +40,6 @@ MSGPACK_ADD_ENUM(outer_enum_class::enum_class_test);
|
||||
|
||||
|
||||
|
||||
#include <msgpack.hpp>
|
||||
|
||||
|
||||
using namespace std;
|
||||
|
||||
const unsigned int kLoop = 1000;
|
||||
|
Reference in New Issue
Block a user