From: Jérémie Astor Date: Sat, 23 Apr 2022 15:22:06 +0000 (+0200) Subject: document expression lambda X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=c899b0f05af520f8ebb5e1c508aa0726ae020bd2;p=gwion.git document expression lambda --- diff --git a/docs/Reference/Functions/Lambdas.mdr b/docs/Reference/Functions/Lambdas.mdr index 8e394ced..99142081 100644 --- a/docs/Reference/Functions/Lambdas.mdr +++ b/docs/Reference/Functions/Lambdas.mdr @@ -13,7 +13,13 @@ You can even use it to ```gwion,editable \ i { <<< "passed '", i, "'" >>>; }(3); ``` +### Short lambdas +if the lambda consists of only one expression, the result of that expression is implicetely returned. +Notice there is no semicolon in the lambda body; +```gwion,editable +<<< \ { 42 }() >>>; +``` ## Use case