summaryrefslogtreecommitdiffstats
path: root/Source/cmJsonObjects.cxx
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2019-07-31 07:06:04 (GMT)
committerSebastian Holtermann <sebholt@xwmw.org>2019-08-05 09:25:30 (GMT)
commit7fbcc16dcd92a80eb30baab93388a0b8e294969b (patch)
tree33958836b22312caaa67cd3eb331c5676e2cf8a7 /Source/cmJsonObjects.cxx
parent3ebd3fa51d229e0067e8ca24f8fa4ed35ee5dac8 (diff)
downloadCMake-7fbcc16dcd92a80eb30baab93388a0b8e294969b.zip
CMake-7fbcc16dcd92a80eb30baab93388a0b8e294969b.tar.gz
CMake-7fbcc16dcd92a80eb30baab93388a0b8e294969b.tar.bz2
cmStringAlgorithms: cmIsSpace, cmTrimWhitespace, cmEscapeQuotes, cmTokenize
This adds the following functions to `cmStringAlgorithms`: - `cmIsSpace` - `cmTrimWhitespace` (moved from `cmSystemTools::TrimWhitespace`) - `cmEscapeQuotes` (moved from `cmSystemTools::EscapeQuotes`) - `cmTokenize` (moved from `cmSystemTools::tokenize` and adapted to accept `cm::string_view`)
Diffstat (limited to 'Source/cmJsonObjects.cxx')
-rw-r--r--Source/cmJsonObjects.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/cmJsonObjects.cxx b/Source/cmJsonObjects.cxx
index 2423faf..953333c 100644
--- a/Source/cmJsonObjects.cxx
+++ b/Source/cmJsonObjects.cxx
@@ -20,6 +20,7 @@
#include "cmStateDirectory.h"
#include "cmStateSnapshot.h"
#include "cmStateTypes.h"
+#include "cmStringAlgorithms.h"
#include "cmSystemTools.h"
#include "cmTarget.h"
#include "cmTest.h"
@@ -541,19 +542,19 @@ static Json::Value DumpTarget(cmGeneratorTarget* target,
lg->GetTargetFlags(&linkLineComputer, config, linkLibs, linkLanguageFlags,
linkFlags, frameworkPath, linkPath, target);
- linkLibs = cmSystemTools::TrimWhitespace(linkLibs);
- linkFlags = cmSystemTools::TrimWhitespace(linkFlags);
- linkLanguageFlags = cmSystemTools::TrimWhitespace(linkLanguageFlags);
- frameworkPath = cmSystemTools::TrimWhitespace(frameworkPath);
- linkPath = cmSystemTools::TrimWhitespace(linkPath);
+ linkLibs = cmTrimWhitespace(linkLibs);
+ linkFlags = cmTrimWhitespace(linkFlags);
+ linkLanguageFlags = cmTrimWhitespace(linkLanguageFlags);
+ frameworkPath = cmTrimWhitespace(frameworkPath);
+ linkPath = cmTrimWhitespace(linkPath);
- if (!cmSystemTools::TrimWhitespace(linkLibs).empty()) {
+ if (!cmTrimWhitespace(linkLibs).empty()) {
result[kLINK_LIBRARIES_KEY] = linkLibs;
}
- if (!cmSystemTools::TrimWhitespace(linkFlags).empty()) {
+ if (!cmTrimWhitespace(linkFlags).empty()) {
result[kLINK_FLAGS_KEY] = linkFlags;
}
- if (!cmSystemTools::TrimWhitespace(linkLanguageFlags).empty()) {
+ if (!cmTrimWhitespace(linkLanguageFlags).empty()) {
result[kLINK_LANGUAGE_FLAGS_KEY] = linkLanguageFlags;
}
if (!frameworkPath.empty()) {