boost_array.hpp 949 B

12345678910111213141516171819202122232425262728293031
  1. #ifndef BOOST_SERIALIZATION_BOOST_ARRAY_HPP
  2. #define BOOST_SERIALIZATION_BOOST_ARRAY_HPP
  3. // (C) Copyright 2005 Matthias Troyer and Dave Abrahams
  4. // Use, modification and distribution is subject to the Boost Software
  5. // License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  6. // http://www.boost.org/LICENSE_1_0.txt)
  7. #include <boost/config.hpp> // msvc 6.0 needs this for warning suppression
  8. #if defined(BOOST_NO_STDC_NAMESPACE)
  9. namespace std{
  10. using ::size_t;
  11. } // namespace std
  12. #endif
  13. #include <boost/serialization/nvp.hpp>
  14. #include <boost/array.hpp>
  15. namespace boost { namespace serialization {
  16. // implement serialization for boost::array
  17. template <class Archive, class T, std::size_t N>
  18. void serialize(Archive& ar, boost::array<T,N>& a, const unsigned int /* version */)
  19. {
  20. ar & boost::serialization::make_nvp("elems", a.elems);
  21. }
  22. } } // end namespace boost::serialization
  23. #endif //BOOST_SERIALIZATION_BOOST_ARRAY_HPP