Make serialization functions for non-basalt types static.

See: https://groups.google.com/d/msg/cerealcpp/WswQi_Sh-bw/Pw0GrfIqFQAJ
This commit is contained in:
Nikolaus Demmel 2019-08-06 01:33:02 +02:00
parent f958a7480d
commit 25ae6d43df
2 changed files with 3 additions and 3 deletions

View File

@ -157,7 +157,7 @@ namespace cereal {
template <class Archive, class _Scalar, int _Rows, int _Cols, int _Options, template <class Archive, class _Scalar, int _Rows, int _Cols, int _Options,
int _MaxRows, int _MaxCols> int _MaxRows, int _MaxCols>
inline static inline
typename std::enable_if<_Rows == Eigen::Dynamic || _Cols == Eigen::Dynamic, typename std::enable_if<_Rows == Eigen::Dynamic || _Cols == Eigen::Dynamic,
void>::type void>::type
save(Archive &ar, const Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, save(Archive &ar, const Eigen::Matrix<_Scalar, _Rows, _Cols, _Options,
@ -171,7 +171,7 @@ inline
template <class Archive, class _Scalar, int _Rows, int _Cols, int _Options, template <class Archive, class _Scalar, int _Rows, int _Cols, int _Options,
int _MaxRows, int _MaxCols> int _MaxRows, int _MaxCols>
inline static inline
typename std::enable_if<_Rows == Eigen::Dynamic || _Cols == Eigen::Dynamic, typename std::enable_if<_Rows == Eigen::Dynamic || _Cols == Eigen::Dynamic,
void>::type void>::type
load(Archive &ar, load(Archive &ar,

View File

@ -222,7 +222,7 @@ void serialize(Archive& ar, basalt::ImageData& m) {
} }
template <class Archive> template <class Archive>
void serialize(Archive& ar, Eigen::AffineCompact2f& m) { static void serialize(Archive& ar, Eigen::AffineCompact2f& m) {
ar(m.matrix()); ar(m.matrix());
} }
} // namespace cereal } // namespace cereal