mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-06 05:40:54 -06:00
cmMakefile: make some methods take const std::string& instead of const char*
Most callers already have a std::string, on which they called c_str() to pass it into these methods, which internally converted it back to std::string. Pass a std::string directly to these methods now, avoiding all these conversions. Those methods that only pass in a const char* will get the conversion to std::string now only once.
This commit is contained in:
committed by
Brad King
parent
4c7bac45ae
commit
c768e398f9
@@ -72,7 +72,7 @@ bool cmSetTargetPropertiesCommand
|
||||
int i;
|
||||
for(i = 0; i < numFiles; ++i)
|
||||
{
|
||||
if (this->Makefile->IsAlias(args[i].c_str()))
|
||||
if (this->Makefile->IsAlias(args[i]))
|
||||
{
|
||||
this->SetError("can not be used on an ALIAS target.");
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user