From 2eaffa5cfb8ad8e5d18ac1ed61b4ae6b976852ee Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Mon, 25 Mar 2024 11:57:42 +0100 Subject: Expression language: add float operations "*" and "+" Numerical values are used at some places in justbuild: as value for timeout scaling, as well as by the "range" expression that is used, e.g., to define repreated test runs. Therefore, improve support for numerical values by adding basic operations. --- doc/concepts/expressions.md | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'doc') diff --git a/doc/concepts/expressions.md b/doc/concepts/expressions.md index dcd567af..192952f4 100644 --- a/doc/concepts/expressions.md +++ b/doc/concepts/expressions.md @@ -259,6 +259,14 @@ those) argument(s) to obtain the final result. - `"++"` The argument has to be a list of lists. The result is the concatenation of those lists. + - `"+"` The argument has to be a list of numbers. The result is + their sum (where the sum of the empty list is, of course, the + neutral element 0). + + - `"*"` The argument has to be a list of numbers. The result + is their product (where the producut of the empty list is, of + course, the neutral element 1). + - `"map_union"` The argument has to be a list of maps. The result is a map containing as keys the union of the keys of the maps in that list. For each key, the value is the value -- cgit v1.2.3