Commit Graph

6 Commits

Author SHA1 Message Date
Stephen Kelly d6a03b475e cmIfCommand: Issue CMP0054 warning with appropriate context. (#15802)
Commit v3.4.0-rc1~494^2~4 (cmMakefile: Add API for elseif to create
backtrace., 2015-05-29) removed the use of cmMakefileCall to push/pop
execution context in favor of a new way to create backtraces.

However, a call to cmMakefile::GetExecutionContext is still invoked to
issue a contextual CMP0054 warning through cmConditionEvaluator.  As
the elseif is not part of the call stack, this resulted in trying to
access an empty vector.

Avoid the attempt at getting execution context when evaluating elseif by
constructing a context and backtrace on behalf of the cmConditionEvaluator
in all cases.
2015-10-20 23:40:12 +02:00
Matt McCormick 14e49ed156 if: Add "TEST <test>" condition
if(TEST TestNameThatExists) will return true if a test with the name
TestNameThatExists has been added with add_test.  The syntax is similar
to if(TARGET TargetName).  Since use of "TEST" as an argument to if()
could previously be interpreted as a non-keyword argument, add policy
CMP0064 to treat it as a keyword as NEW behavior.
2015-08-03 09:22:25 -04:00
Nils Gladitz aed6239e40 if: Implement new IN_LIST operator 2015-04-30 10:21:19 -04:00
Stephen Kelly af65da0aa9 cmStandardIncludes: Remove list include.
Include it only where used.
2015-02-06 19:04:53 +01:00
Nils Gladitz 188a1f236e If: Introduce policy CMP0054 - don't dereference quoted variables in if() 2014-09-11 21:23:17 +02:00
Nils Gladitz b900c1ccaa If: Extract cmConditionEvaluator from if() implementation 2014-09-11 21:17:09 +02:00