From 67d799852492743a93a464002395ccb624514fb8 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Sat, 30 Jan 2021 11:25:42 +0200 Subject: Add std::{map, multimap} to types.hxx Seeing that std::map is becoming a common Buildfile variable type. --- libbuild2/variable.hxx | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'libbuild2/variable.hxx') diff --git a/libbuild2/variable.hxx b/libbuild2/variable.hxx index a04e0a9..2d85af3 100644 --- a/libbuild2/variable.hxx +++ b/libbuild2/variable.hxx @@ -4,7 +4,6 @@ #ifndef LIBBUILD2_VARIABLE_HXX #define LIBBUILD2_VARIABLE_HXX -#include #include #include // aligned_storage #include @@ -1126,9 +1125,9 @@ namespace build2 struct map_value_type; template - struct value_traits> + struct value_traits> { - template using map = std::map; + template using map = map; static_assert (sizeof (map) <= value::size_, "insufficient space"); @@ -1167,19 +1166,19 @@ namespace build2 value_traits>>>; extern template struct LIBBUILD2_DECEXPORT - value_traits>; + value_traits>; extern template struct LIBBUILD2_DECEXPORT - value_traits>>; + value_traits>>; extern template struct LIBBUILD2_DECEXPORT - value_traits, string>>; + value_traits, string>>; extern template struct LIBBUILD2_DECEXPORT - value_traits>>; + value_traits>>; extern template struct LIBBUILD2_DECEXPORT - value_traits>; // var_subprojects + value_traits>; // var_subprojects // Project-wide (as opposed to global) variable overrides (see context ctor // for details). @@ -1712,7 +1711,7 @@ namespace build2 stem_version (sver) {} }; - using map_type = std::map; + using map_type = map; map_type m_; }; @@ -1734,7 +1733,7 @@ namespace build2 class variable_pattern_map { public: - using map_type = std::map; + using map_type = map; using const_iterator = map_type::const_iterator; using const_reverse_iterator = map_type::const_reverse_iterator; @@ -1762,7 +1761,7 @@ namespace build2 class LIBBUILD2_SYMEXPORT variable_type_map { public: - using map_type = std::map, + using map_type = map, variable_pattern_map>; using const_iterator = map_type::const_iterator; -- cgit v1.1