From 39ba13266bbd3d3cde77698dfba37ef83f155607 Mon Sep 17 00:00:00 2001 From: Max Lyon Date: Mon, 15 Mar 2021 13:55:43 +0100 Subject: [PATCH] remove binary specialization for vector of string --- src/OpenMesh/Core/IO/SR_binary_spec.hh | 1 - .../Core/IO/SR_binary_vector_of_string.inl | 40 ------------------- 2 files changed, 41 deletions(-) delete mode 100644 src/OpenMesh/Core/IO/SR_binary_vector_of_string.inl diff --git a/src/OpenMesh/Core/IO/SR_binary_spec.hh b/src/OpenMesh/Core/IO/SR_binary_spec.hh index 22a522d7..2bb7ceeb 100644 --- a/src/OpenMesh/Core/IO/SR_binary_spec.hh +++ b/src/OpenMesh/Core/IO/SR_binary_spec.hh @@ -424,7 +424,6 @@ struct binary< std::vector< T > > { } }; -#include #include // ---------------------------------------------------------------------------- diff --git a/src/OpenMesh/Core/IO/SR_binary_vector_of_string.inl b/src/OpenMesh/Core/IO/SR_binary_vector_of_string.inl deleted file mode 100644 index 43d3f0bc..00000000 --- a/src/OpenMesh/Core/IO/SR_binary_vector_of_string.inl +++ /dev/null @@ -1,40 +0,0 @@ - -template <> struct binary< std::vector< std::string > > -{ - // struct binary interface - - typedef std::vector< std::string > value_type; - typedef value_type::value_type elem_type; - - static const bool is_streamable = true; - - // Helper - - struct Sum - { - size_t operator() ( size_t _v1, const elem_type& _s2 ) - { return _v1 + binary::size_of(_s2); } - }; - - // struct binary interface - - static size_t size_of(bool _store_size = true) { return UnknownSize; } - - static size_t size_of(const value_type& _v, bool _store_size = true) - { return std::accumulate( _v.begin(), _v.end(), size_t(0), Sum() ); } - - static std::string string_for_value_type(void) { return get_string_for_type(value_type()); } - static - size_t store(std::ostream& _os, const value_type& _v, bool _swap=false, bool _store_size = true) - { - return std::accumulate( _v.begin(), _v.end(), size_t(0), - FunctorStore(_os, _swap) ); - } - - static - size_t restore(std::istream& _is, value_type& _v, bool _swap=false, bool _restore_size = true) - { - return std::accumulate( _v.begin(), _v.end(), size_t(0), - FunctorRestore(_is, _swap) ); - } -};