diff options
author | Ben Boeckel <ben.boeckel@kitware.com> | 2014-02-10 05:21:34 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-03-08 18:05:35 (GMT) |
commit | 270eb96df05b93023cdd3d3a186b44b4ece1d655 (patch) | |
tree | 25d3037b5412b24242c631cccfe36e16a0fa8e1c /Source/cmCTest.cxx | |
parent | 215b1addf09359507281359cd7d478c61c01a9f2 (diff) | |
download | CMake-270eb96df05b93023cdd3d3a186b44b4ece1d655.zip CMake-270eb96df05b93023cdd3d3a186b44b4ece1d655.tar.gz CMake-270eb96df05b93023cdd3d3a186b44b4ece1d655.tar.bz2 |
strings: Remove cmStdString references
Casts from std::string -> cmStdString were high on the list of things
taking up time. Avoid such implicit casts across function calls by just
using std::string everywhere.
The comment that the symbol name is too long is no longer relevant since
modern debuggers alias the templates anyways and the size is a
non-issue since the underlying methods are generated since it's
inherited.
Diffstat (limited to 'Source/cmCTest.cxx')
-rw-r--r-- | Source/cmCTest.cxx | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx index 72bb7fd..ee9b664 100644 --- a/Source/cmCTest.cxx +++ b/Source/cmCTest.cxx @@ -1153,7 +1153,7 @@ int cmCTest::RunMakeCommand(const char* command, std::string* output, int* retVal, const char* dir, int timeout, std::ostream& ofs) { // First generate the command and arguments - std::vector<cmStdString> args = cmSystemTools::ParseArguments(command); + std::vector<std::string> args = cmSystemTools::ParseArguments(command); if(args.size() < 1) { @@ -1161,7 +1161,7 @@ int cmCTest::RunMakeCommand(const char* command, std::string* output, } std::vector<const char*> argv; - for(std::vector<cmStdString>::const_iterator a = args.begin(); + for(std::vector<std::string>::const_iterator a = args.begin(); a != args.end(); ++a) { argv.push_back(a->c_str()); @@ -1637,7 +1637,7 @@ int cmCTest::GenerateCTestNotesOutput(std::ostream& os, } //---------------------------------------------------------------------- -int cmCTest::GenerateNotesFile(const std::vector<cmStdString> &files) +int cmCTest::GenerateNotesFile(const VectorOfStrings &files) { cmGeneratedFileStream ofs; if ( !this->OpenOutputFile(this->CurrentTag, "Notes.xml", ofs) ) @@ -1658,7 +1658,7 @@ int cmCTest::GenerateNotesFile(const char* cfiles) return 1; } - std::vector<cmStdString> files; + VectorOfStrings files; cmCTestLog(this, OUTPUT, "Create notes file" << std::endl); @@ -1675,7 +1675,7 @@ int cmCTest::GenerateNotesFile(const char* cfiles) std::string cmCTest::Base64GzipEncodeFile(std::string file) { std::string tarFile = file + "_temp.tar.gz"; - std::vector<cmStdString> files; + std::vector<std::string> files; files.push_back(file); if(!cmSystemTools::CreateTar(tarFile.c_str(), files, true, false, false)) @@ -1722,9 +1722,9 @@ std::string cmCTest::Base64EncodeFile(std::string file) //---------------------------------------------------------------------- -bool cmCTest::SubmitExtraFiles(const std::vector<cmStdString> &files) +bool cmCTest::SubmitExtraFiles(const VectorOfStrings &files) { - std::vector<cmStdString>::const_iterator it; + VectorOfStrings::const_iterator it; for ( it = files.begin(); it != files.end(); ++ it ) @@ -1749,7 +1749,7 @@ bool cmCTest::SubmitExtraFiles(const char* cfiles) return 1; } - std::vector<cmStdString> files; + VectorOfStrings files; cmCTestLog(this, OUTPUT, "Submit extra files" << std::endl); @@ -2594,7 +2594,7 @@ int cmCTest::ReadCustomConfigurationFileTree(const char* dir, cmMakefile* mf) //---------------------------------------------------------------------- void cmCTest::PopulateCustomVector(cmMakefile* mf, const std::string& def, - VectorOfStrings& vec) + std::vector<std::string>& vec) { const char* dval = mf->GetDefinition(def); if ( !dval ) @@ -2892,7 +2892,7 @@ bool cmCTest::RunCommand( const char* dir, double timeout) { - std::vector<cmStdString> args = cmSystemTools::ParseArguments(command); + std::vector<std::string> args = cmSystemTools::ParseArguments(command); if(args.size() < 1) { @@ -2900,7 +2900,7 @@ bool cmCTest::RunCommand( } std::vector<const char*> argv; - for(std::vector<cmStdString>::const_iterator a = args.begin(); + for(std::vector<std::string>::const_iterator a = args.begin(); a != args.end(); ++a) { argv.push_back(a->c_str()); |