Skip to content

Commit b827b95

Browse files
committed
Fixes need for special MSVC case, see #373
1 parent fb6606d commit b827b95

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

unittests/polymorphic.hpp

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -53,17 +53,14 @@ struct PolyBaseAA : PolyBaseA
5353
ar( w );
5454
}
5555

56-
static void doesNothing()
57-
{
58-
cereal::detail::RegisterPolymorphicCaster<PolyBaseA, PolyBaseAA>::bind();
59-
}
60-
6156
bool operator==( PolyBaseAA const & other ) const
6257
{
6358
return w == other.w;
6459
}
6560
};
6661

62+
CEREAL_REGISTER_POLYMORPHIC_RELATION(PolyBaseA, PolyBaseAA)
63+
6764
struct PolyBaseB : virtual PolyBaseAA
6865
{
6966
PolyBaseB() {}
@@ -131,9 +128,6 @@ struct PolyDerivedD : PolyBaseB, PolyBaseC
131128
};
132129

133130
CEREAL_REGISTER_TYPE(PolyDerivedD)
134-
#ifdef _MSC_VER
135-
CEREAL_REGISTER_POLYMORPHIC_RELATION(PolyBaseA, PolyDerivedD)
136-
#endif
137131

138132
struct PolyBase
139133
{

0 commit comments

Comments
 (0)