Replace foo.length() pattern with !foo.empty().

This commit is contained in:
Stephen Kelly
2015-01-15 23:39:38 +01:00
parent fd0c036c0c
commit 5f69314ea6
5 changed files with 8 additions and 8 deletions

View File

@@ -160,7 +160,7 @@ bool cmLoadCacheCommand::ReadWithPrefix(std::vector<std::string> const& args)
}
}
}
if(line.length())
if(!line.empty())
{
// Partial last line.
this->CheckLine(line.c_str());
@@ -184,7 +184,7 @@ void cmLoadCacheCommand::CheckLine(const char* line)
// This was requested. Set this variable locally with the given
// prefix.
var = this->Prefix + var;
if(value.length())
if(!value.empty())
{
this->Makefile->AddDefinition(var, value.c_str());
}