From 9486769866661e3aa76dd588ca5a7466e2969dc3 Mon Sep 17 00:00:00 2001 From: Stephen Kelly Date: Tue, 5 May 2015 21:50:39 +0200 Subject: Don't use a cmLocalGenerator instance to call static methods. --- Source/cmIfCommand.cxx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'Source/cmIfCommand.cxx') diff --git a/Source/cmIfCommand.cxx b/Source/cmIfCommand.cxx index 6dea5c17cf..3551f837e1 100644 --- a/Source/cmIfCommand.cxx +++ b/Source/cmIfCommand.cxx @@ -20,15 +20,14 @@ static std::string cmIfCommandError( - cmMakefile* mf, std::vector const& args) + std::vector const& args) { - cmLocalGenerator* lg = mf->GetLocalGenerator(); std::string err = "given arguments:\n "; for(std::vector::const_iterator i = args.begin(); i != args.end(); ++i) { err += " "; - err += lg->EscapeForCMake(i->GetValue()); + err += cmLocalGenerator::EscapeForCMake(i->GetValue()); } err += "\n"; return err; @@ -118,7 +117,7 @@ IsFunctionBlocked(const cmListFileFunction& lff, if (!errorString.empty()) { - std::string err = cmIfCommandError(&mf, expandedArguments); + std::string err = cmIfCommandError(expandedArguments); err += errorString; mf.IssueMessage(messType, err); if (messType == cmake::FATAL_ERROR) @@ -206,7 +205,7 @@ bool cmIfCommand if (!errorString.empty()) { - std::string err = cmIfCommandError(this->Makefile, expandedArguments); + std::string err = cmIfCommandError(expandedArguments); err += errorString; if (status == cmake::FATAL_ERROR) { -- cgit v1.2.1