summaryrefslogtreecommitdiff
path: root/Source/cmPropertyMap.cxx
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2019-06-02 12:35:33 +0200
committerSebastian Holtermann <sebholt@xwmw.org>2019-06-08 12:25:35 +0200
commit9e64e617eb295c7e2725d871225659ae7bcf7c48 (patch)
tree5356b70a28cd1ad5de06dcadc035489b6645c529 /Source/cmPropertyMap.cxx
parentf4bbeb785c8f673a5cff326cc717d0dfbb2734a2 (diff)
downloadcmake-9e64e617eb295c7e2725d871225659ae7bcf7c48.tar.gz
cmPropertyMap: Rename GetPropertyList method to GetKeys
Diffstat (limited to 'Source/cmPropertyMap.cxx')
-rw-r--r--Source/cmPropertyMap.cxx21
1 files changed, 10 insertions, 11 deletions
diff --git a/Source/cmPropertyMap.cxx b/Source/cmPropertyMap.cxx
index 3f6d7c8a9f..a97e1f0713 100644
--- a/Source/cmPropertyMap.cxx
+++ b/Source/cmPropertyMap.cxx
@@ -2,7 +2,6 @@
file Copyright.txt or https://cmake.org/licensing for details. */
#include "cmPropertyMap.h"
-#include <algorithm>
#include <assert.h>
#include <utility>
@@ -18,16 +17,6 @@ cmProperty* cmPropertyMap::GetOrCreateProperty(const std::string& name)
return prop;
}
-std::vector<std::string> cmPropertyMap::GetPropertyList() const
-{
- std::vector<std::string> keyList;
- for (auto const& i : *this) {
- keyList.push_back(i.first);
- }
- std::sort(keyList.begin(), keyList.end());
- return keyList;
-}
-
void cmPropertyMap::SetProperty(const std::string& name, const char* value)
{
if (!value) {
@@ -61,3 +50,13 @@ const char* cmPropertyMap::GetPropertyValue(const std::string& name) const
}
return it->second.GetValue();
}
+
+std::vector<std::string> cmPropertyMap::GetKeys() const
+{
+ std::vector<std::string> keyList;
+ keyList.reserve(this->size());
+ for (auto const& item : *this) {
+ keyList.push_back(item.first);
+ }
+ return keyList;
+}