diff options
Diffstat (limited to 'Source/cmWhileCommand.cxx')
-rw-r--r-- | Source/cmWhileCommand.cxx | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/Source/cmWhileCommand.cxx b/Source/cmWhileCommand.cxx index 7d2eead..5565b8a 100644 --- a/Source/cmWhileCommand.cxx +++ b/Source/cmWhileCommand.cxx @@ -10,7 +10,7 @@ See the License for more information. ============================================================================*/ #include "cmWhileCommand.h" -#include "cmIfCommand.h" +#include "cmConditionEvaluator.h" bool cmWhileFunctionBlocker:: IsFunctionBlocked(const cmListFileFunction& lff, cmMakefile &mf, @@ -37,9 +37,11 @@ IsFunctionBlocked(const cmListFileFunction& lff, cmMakefile &mf, std::vector<std::string> expandedArguments; mf.ExpandArguments(this->Args, expandedArguments); cmake::MessageType messageType; - bool isTrue = - cmIfCommand::IsTrue(expandedArguments,errorString, - &mf, messageType); + + cmConditionEvaluator conditionEvaluator(mf); + + bool isTrue = conditionEvaluator.IsTrue( + expandedArguments, errorString, messageType); while (isTrue) { @@ -86,9 +88,8 @@ IsFunctionBlocked(const cmListFileFunction& lff, cmMakefile &mf, } expandedArguments.clear(); mf.ExpandArguments(this->Args, expandedArguments); - isTrue = - cmIfCommand::IsTrue(expandedArguments,errorString, - &mf, messageType); + isTrue = conditionEvaluator.IsTrue( + expandedArguments, errorString, messageType); } return true; } |