summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalXCodeGenerator.cxx
diff options
context:
space:
mode:
authorRolf Eike Beer <eike@sf-mail.de>2016-04-20 21:14:52 (GMT)
committerRolf Eike Beer <eike@sf-mail.de>2016-04-20 21:34:57 (GMT)
commitffedf3527d7e714b6885b822ee85889016418ebb (patch)
tree5e777747aa2ed1840ec9660520b9a9319dd40534 /Source/cmGlobalXCodeGenerator.cxx
parent6100bdff38580d297c098127e9bc0105b7a33e06 (diff)
downloadCMake-ffedf3527d7e714b6885b822ee85889016418ebb.zip
CMake-ffedf3527d7e714b6885b822ee85889016418ebb.tar.gz
CMake-ffedf3527d7e714b6885b822ee85889016418ebb.tar.bz2
make cmGlobalXCodeGenerator::BuildObjectListOrString::Add() take a string&
All callers already have these objects, and it is only passed to other methods taking such, so avoid all conversions in between.
Diffstat (limited to 'Source/cmGlobalXCodeGenerator.cxx')
-rw-r--r--Source/cmGlobalXCodeGenerator.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index 0050bf4..5e68345 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -84,7 +84,7 @@ public:
bool IsEmpty() const { return this->Empty; }
- void Add(const char *newString)
+ void Add(const std::string& newString)
{
this->Empty = false;
@@ -2285,14 +2285,14 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmGeneratorTarget* gtgt,
frameworkDir = cmSystemTools::CollapseFullPath(frameworkDir.c_str());
if(emitted.insert(frameworkDir).second)
{
- fdirs.Add(this->XCodeEscapePath(frameworkDir.c_str()).c_str());
+ fdirs.Add(this->XCodeEscapePath(frameworkDir.c_str()));
}
}
else
{
std::string incpath =
this->XCodeEscapePath(i->c_str());
- dirs.Add(incpath.c_str());
+ dirs.Add(incpath);
}
}
// Add framework search paths needed for linking.
@@ -2304,7 +2304,7 @@ void cmGlobalXCodeGenerator::CreateBuildSettings(cmGeneratorTarget* gtgt,
{
if(emitted.insert(*fdi).second)
{
- fdirs.Add(this->XCodeEscapePath(fdi->c_str()).c_str());
+ fdirs.Add(this->XCodeEscapePath(fdi->c_str()));
}
}
}
@@ -4025,7 +4025,7 @@ cmGlobalXCodeGenerator::AppendDefines(BuildObjectListOrString& defs,
// Append the flag with needed escapes.
std::string tmp;
this->AppendFlag(tmp, def);
- defs.Add(tmp.c_str());
+ defs.Add(tmp);
}
}