[Cmake-commits] [cmake-commits] king committed cmMakefile.cxx 1.462 1.463

cmake-commits at cmake.org cmake-commits at cmake.org
Thu Mar 13 14:13:46 EDT 2008


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv11413/Source

Modified Files:
	cmMakefile.cxx 
Log Message:
ENH: Improve error message when invalid policy is given.


Index: cmMakefile.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmMakefile.cxx,v
retrieving revision 1.462
retrieving revision 1.463
diff -C 2 -d -r1.462 -r1.463
*** cmMakefile.cxx	13 Mar 2008 17:48:57 -0000	1.462
--- cmMakefile.cxx	13 Mar 2008 18:13:44 -0000	1.463
***************
*** 3333,3341 ****
    cmPolicies::PolicyID pid;
    if (!this->GetPolicies()->GetPolicyID(id, /* out */ pid))
!   {
!     cmSystemTools::Error("Invalid policy string used. Invalid string was "
!       , id);
      return false;
!   }
    return this->SetPolicy(pid,status);
  }
--- 3333,3342 ----
    cmPolicies::PolicyID pid;
    if (!this->GetPolicies()->GetPolicyID(id, /* out */ pid))
!     {
!     cmOStringStream e;
!     e << "Policy \"" << id << "\" is not known to this version of CMake.";
!     this->IssueMessage(cmake::FATAL_ERROR, e.str());
      return false;
!     }
    return this->SetPolicy(pid,status);
  }



More information about the Cmake-commits mailing list