summaryrefslogtreecommitdiff
path: root/Source/cmIfCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-04-14 10:31:44 -0400
committerBrad King <brad.king@kitware.com>2016-04-15 08:29:42 -0400
commit7503deb2c55a32f72c9ec34f17a800d4ab1e4c75 (patch)
treed1650d69bcb0cdb52c345448119ed7b3deb2ec4f /Source/cmIfCommand.cxx
parentf5da19edd00e05eb39332fe416f0b2bb77abadaa (diff)
downloadcmake-7503deb2c55a32f72c9ec34f17a800d4ab1e4c75.tar.gz
cmIfCommand: Simplify execution context construction
Diffstat (limited to 'Source/cmIfCommand.cxx')
-rw-r--r--Source/cmIfCommand.cxx10
1 files changed, 2 insertions, 8 deletions
diff --git a/Source/cmIfCommand.cxx b/Source/cmIfCommand.cxx
index 9a07dded44..fc54ca5aa5 100644
--- a/Source/cmIfCommand.cxx
+++ b/Source/cmIfCommand.cxx
@@ -203,15 +203,9 @@ bool cmIfCommand
cmake::MessageType status;
- cmListFileContext execContext = this->Makefile->GetExecutionContext();
-
- cmCommandContext commandContext;
- commandContext.Line = execContext.Line;
- commandContext.Name = execContext.Name;
-
cmConditionEvaluator conditionEvaluator(
- *(this->Makefile), cmListFileContext::FromCommandContext(
- commandContext, execContext.FilePath),
+ *(this->Makefile),
+ this->Makefile->GetExecutionContext(),
this->Makefile->GetBacktrace());
bool isTrue = conditionEvaluator.IsTrue(