summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2015-01-15 22:04:33 (GMT)
committerStephen Kelly <steveire@gmail.com>2015-01-18 13:25:24 (GMT)
commitfd7b37129360364531ddfeda7edb6e34ba773d00 (patch)
tree701d9b298e1030b901a507b436e162810af3b8cc /Source/cmMakefile.cxx
parentaa773035b7f4a1aefd860d0b9e80f134bd4a4547 (diff)
downloadCMake-fd7b37129360364531ddfeda7edb6e34ba773d00.zip
CMake-fd7b37129360364531ddfeda7edb6e34ba773d00.tar.gz
CMake-fd7b37129360364531ddfeda7edb6e34ba773d00.tar.bz2
Replace foo.size() pattern with !foo.empty().
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 67efdc5..87e62d7 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -1798,7 +1798,7 @@ void cmMakefile::AddDefinition(const std::string& name, const char* value)
}
this->Internal->VarStack.top().Set(name, value);
- if (this->Internal->VarUsageStack.size() &&
+ if (!this->Internal->VarUsageStack.empty() &&
this->VariableInitialized(name))
{
this->CheckForUnused("changing definition", name);
@@ -1873,7 +1873,7 @@ void cmMakefile::AddCacheDefinition(const std::string& name, const char* value,
void cmMakefile::AddDefinition(const std::string& name, bool value)
{
this->Internal->VarStack.top().Set(name, value? "ON" : "OFF");
- if (this->Internal->VarUsageStack.size() &&
+ if (!this->Internal->VarUsageStack.empty() &&
this->VariableInitialized(name))
{
this->CheckForUnused("changing definition", name);
@@ -1937,7 +1937,7 @@ void cmMakefile::CheckForUnused(const char* reason,
{
std::string path;
cmListFileBacktrace bt(this->GetLocalGenerator());
- if (this->CallStack.size())
+ if (!this->CallStack.empty())
{
const cmListFileContext* file = this->CallStack.back().Context;
bt.push_back(*file);
@@ -1972,7 +1972,7 @@ void cmMakefile::CheckForUnused(const char* reason,
void cmMakefile::RemoveDefinition(const std::string& name)
{
this->Internal->VarStack.top().Set(name, 0);
- if (this->Internal->VarUsageStack.size() &&
+ if (!this->Internal->VarUsageStack.empty() &&
this->VariableInitialized(name))
{
this->CheckForUnused("unsetting", name);