cereal
A C++11 library for serialization
|
Casts a derived class to its non-virtual base class in a way that safely supports abstract classes. More...
#include </build/libcereal-B5G4p0/libcereal-1.1.2/include/cereal/types/base_class.hpp>
Public Member Functions | |
template<class Derived > | |
base_class (Derived const *derived) | |
Public Attributes | |
Base * | base_ptr |
Casts a derived class to its non-virtual base class in a way that safely supports abstract classes.
This should be used in cases when a derived type needs to serialize its base type. This is better than directly using static_cast, as it allows for serialization of pure virtual (abstract) base classes.