Merge topic 'target-command-allow-no-items'

c0b8682 Allow target commands to be invoked with no items (#14325).
This commit is contained in:
Brad King
2013-08-01 08:52:35 -04:00
committed by CMake Topic Stage
4 changed files with 27 additions and 3 deletions
+3 -3
View File
@@ -19,7 +19,7 @@ bool cmTargetPropCommandBase
::HandleArguments(std::vector<std::string> const& args, const char *prop,
ArgumentFlags flags)
{
if(args.size() < 3)
if(args.size() < 2)
{
this->SetError("called with incorrect number of arguments");
return false;
@@ -53,7 +53,7 @@ bool cmTargetPropCommandBase
if ((flags & PROCESS_SYSTEM) && args[argIndex] == "SYSTEM")
{
if (args.size() < 4)
if (args.size() < 3)
{
this->SetError("called with incorrect number of arguments");
return false;
@@ -65,7 +65,7 @@ bool cmTargetPropCommandBase
bool prepend = false;
if ((flags & PROCESS_BEFORE) && args[argIndex] == "BEFORE")
{
if (args.size() < 4)
if (args.size() < 3)
{
this->SetError("called with incorrect number of arguments");
return false;