summaryrefslogtreecommitdiff
path: root/configmgr
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-05-06 10:41:18 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-05-06 10:41:18 +0200
commit03d960ac112c0e00bb72c1b570c65113a5cf280f (patch)
tree16ab0a25723c0b2a1494d71b35b776ddcaa41eba /configmgr
parentcbcc6189e300b6aa5e9e8e6883598a4d28b770c0 (diff)
Avoid using incomplete types with std containers
...which is explicitly supported by Boost.Container though, but we cannot use boost::container::map here as Boost.Container is only available since Boost 1.48 and our base is 1.47 still. However, there appears no need for Children to be sorted, and std::unordered_map (and thus boost::unordered_map) requires that pointers to elements are not invalidated by insertions, which we do require. Change-Id: I70ad6f40318d2bafae53ebb67d84c1c89a7d68f6
Diffstat (limited to 'configmgr')
-rw-r--r--configmgr/source/modifications.hxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/configmgr/source/modifications.hxx b/configmgr/source/modifications.hxx
index f55e9de2e5e3..ff12651b1620 100644
--- a/configmgr/source/modifications.hxx
+++ b/configmgr/source/modifications.hxx
@@ -22,8 +22,7 @@
#include "sal/config.h"
-#include <map>
-
+#include "boost/unordered_map.hpp"
#include "boost/noncopyable.hpp"
#include "path.hxx"
@@ -34,7 +33,7 @@ namespace configmgr {
class Modifications: private boost::noncopyable {
public:
struct Node {
- typedef std::map< OUString, Node > Children;
+ typedef boost::unordered_map<OUString, Node, OUStringHash> Children;
Children children;
};