diff options
author | Stephen Kelly <steveire@gmail.com> | 2015-01-14 23:31:49 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2015-01-18 13:25:24 (GMT) |
commit | 930bd4781694ea85a876c08c34a2dd8243688920 (patch) | |
tree | 399ea4dd7a803f40ea986dc58eaa12c61ab923b6 /Source/cmGlobalGenerator.cxx | |
parent | d92887efabad6a91e221588d0dc7a0bffd91a9f7 (diff) | |
download | CMake-930bd4781694ea85a876c08c34a2dd8243688920.zip CMake-930bd4781694ea85a876c08c34a2dd8243688920.tar.gz CMake-930bd4781694ea85a876c08c34a2dd8243688920.tar.bz2 |
Replace 'foo.size() == 0' pattern with foo.empty().
Diffstat (limited to 'Source/cmGlobalGenerator.cxx')
-rw-r--r-- | Source/cmGlobalGenerator.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx index 6373235..5ebc7cc 100644 --- a/Source/cmGlobalGenerator.cxx +++ b/Source/cmGlobalGenerator.cxx @@ -174,7 +174,7 @@ void cmGlobalGenerator::ResolveLanguageCompiler(const std::string &lang, { path = name; } - if((path.size() == 0 || !cmSystemTools::FileExists(path.c_str())) + if((path.empty() || !cmSystemTools::FileExists(path.c_str())) && (optional==false)) { return; @@ -265,7 +265,7 @@ cmGlobalGenerator::IsExportedTargetsFile(const std::string &filename) const // Find the make program for the generator, required for try compiles void cmGlobalGenerator::FindMakeProgram(cmMakefile* mf) { - if(this->FindMakeProgramFile.size() == 0) + if(this->FindMakeProgramFile.empty()) { cmSystemTools::Error( "Generator implementation error, " @@ -383,7 +383,7 @@ void cmGlobalGenerator::EnableLanguage(std::vector<std::string>const& languages, cmMakefile *mf, bool optional) { - if(languages.size() == 0) + if(languages.empty()) { cmSystemTools::Error("EnableLanguage must have a lang specified!"); cmSystemTools::SetFatalErrorOccured(); |