From 82a52081693135ec6b0294994db88b47f42e706b Mon Sep 17 00:00:00 2001 From: ljfa-ag Date: Wed, 12 Aug 2015 11:42:15 +0200 Subject: Add typedef for map type used by tag_compound Allows easy switch to unordered_map --- include/tag_compound.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/include/tag_compound.h b/include/tag_compound.h index 60376d2446..7ec53e4f80 100644 --- a/include/tag_compound.h +++ b/include/tag_compound.h @@ -31,10 +31,12 @@ namespace nbt ///Tag that contains multiple unordered named tags of arbitrary types class tag_compound final : public detail::crtp_tag { + typedef std::map map_t_; + public: //Iterator types - typedef std::map::iterator iterator; - typedef std::map::const_iterator const_iterator; + typedef map_t_::iterator iterator; + typedef map_t_::const_iterator const_iterator; ///The type of the tag static constexpr tag_type type = tag_type::Compound; @@ -123,7 +125,7 @@ public: friend bool operator!=(const tag_compound& lhs, const tag_compound& rhs); private: - std::map tags; + map_t_ tags; }; template -- cgit 0.0.5-2-1-g0f52