From ace1743f7f78bb13f99553d6e97ad1beecf1ba99 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 13 Apr 2015 15:50:17 +0200 Subject: Add separate type to represent directory paths --- build/path-map | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'build/path-map') diff --git a/build/path-map b/build/path-map index ee2dd79..2b32b0d 100644 --- a/build/path-map +++ b/build/path-map @@ -24,10 +24,10 @@ namespace build // want a particular representation, pre-populate the map with // it. // - template - struct compare_prefix>: compare_prefix> + template + struct compare_prefix>: compare_prefix> { - typedef basic_path K; + typedef basic_path key_type; typedef C delimiter_type; typedef std::basic_string string_type; @@ -37,7 +37,7 @@ namespace build compare_prefix (delimiter_type d): base (d) {} bool - operator() (const K& x, const K& y) const + operator() (const key_type& x, const key_type& y) const { const auto& xs (x.string ()); const auto& ys (y.string ()); @@ -56,7 +56,7 @@ namespace build } bool - prefix (const K& p, const K& k) const + prefix (const key_type& p, const key_type& k) const { const auto& ps (p.string ()); const auto& ks (k.string ()); @@ -72,6 +72,10 @@ namespace build template using path_map = prefix_map; + + template + using dir_path_map = + prefix_map; } #endif // BUILD_PATH_MAP -- cgit v1.1