Missing const on weak_ptr lock, addresses part of issue #43
This commit is contained in:
@@ -77,7 +77,7 @@ namespace cereal
|
||||
typename std::enable_if<!std::is_polymorphic<T>::value, void>::type
|
||||
save( Archive & ar, std::weak_ptr<T> const & ptr )
|
||||
{
|
||||
auto sptr = ptr.lock();
|
||||
auto const sptr = ptr.lock();
|
||||
ar( _CEREAL_NVP("ptr_wrapper", memory_detail::make_ptr_wrapper( sptr )) );
|
||||
}
|
||||
|
||||
|
||||
@@ -85,6 +85,10 @@
|
||||
} } /* end namespaces */ \
|
||||
CEREAL_BIND_TO_ARCHIVES(T)
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#undef CONSTEXPR
|
||||
#endif
|
||||
|
||||
namespace cereal
|
||||
{
|
||||
namespace polymorphic_detail
|
||||
|
||||
Reference in New Issue
Block a user