From 20b6561e78f5acceecae7c6fc330f7f7de4f2223 Mon Sep 17 00:00:00 2001 From: "Joachim Wuttke (h)" Date: Sun, 4 Nov 2018 15:23:00 +0100 Subject: Help: new section on conditional generator expressions Before, the closely related signatures $ $ were explained in two different sections. The former section was badly explained, with '0' and '1' in place of the formal parameter 'condition'. --- Help/manual/cmake-generator-expressions.7.rst | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/Help/manual/cmake-generator-expressions.7.rst b/Help/manual/cmake-generator-expressions.7.rst index 6f17812..094bfc1 100644 --- a/Help/manual/cmake-generator-expressions.7.rst +++ b/Help/manual/cmake-generator-expressions.7.rst @@ -25,6 +25,21 @@ conditional include directories, and more. The conditions may be based on the build configuration, target properties, platform information or any other queryable information. +Conditional Expressions +======================= + +Conditional expressions depend on a boolean condition that must be +``0`` or ``1``. + +``$`` + Evaluates to ``true_value`` if ``condition`` is ``1``. + Otherwise evaluates to the empty string. + +``$`` + Evaluates to ``true_value`` if ``condition`` is ``1``. + Otherwise evaluates to ``false_value``. + + Logical Expressions =================== @@ -58,10 +73,6 @@ Available logical expressions are: ``$`` ``0`` if ``condition`` is ``1``, else ``1`` -``$`` - ``true_value`` if ``condition`` is ``1``, - ``false_value`` if ``condition`` is ``0`` - ``$`` ``1`` if ``a`` is STREQUAL ``b``, else ``0`` ``$`` @@ -289,10 +300,6 @@ where ``${prop}`` refers to a helper variable: Available output expressions are: -``$<0:...>`` - Empty string (ignores ``...``) -``$<1:...>`` - Content of ``...`` ``$`` Joins the list with the content of ``...`` ``$`` -- cgit v0.12