mirror of
https://github.com/USCiLab/cereal.git
synced 2025-10-18 01:45:52 +02:00
const_cast for save(), seeking for binary_oarchive
Using const cast to get rid of having two versions of save (changed vector and array so far) Initial implementation of seeking to allow saving and restoring position within a binary archive
This commit is contained in:
@@ -31,15 +31,6 @@ namespace cereal
|
||||
ar & i;
|
||||
}
|
||||
|
||||
//! Saving for non-const std::array all other types to binary
|
||||
template <class T, size_t N>
|
||||
typename std::enable_if<!std::is_arithmetic<T>::value, void>::type
|
||||
save( BinaryOutputArchive & ar, std::array<T, N> & array )
|
||||
{
|
||||
for( auto & i : array )
|
||||
ar & i;
|
||||
}
|
||||
|
||||
//! Loading for std::array all other types to binary
|
||||
template <class T, size_t N>
|
||||
typename std::enable_if<!std::is_arithmetic<T>::value, void>::type
|
||||
|
||||
Reference in New Issue
Block a user