From cc8fd1e5884bdfeb57e0655418b58f715be6f6fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Delfino?= Date: Tue, 22 May 2018 02:57:45 -0300 Subject: [PATCH] Fix lambda parameters being refered as arguments (GH-7037) (cherry picked from commit 268cc7c3f8f58075b42ff0cd6b6c6c5d76044895) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Andrés Delfino --- Doc/glossary.rst | 2 +- Doc/reference/expressions.rst | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/glossary.rst b/Doc/glossary.rst index 4b1722f5c036ba..66964692ccbac1 100644 --- a/Doc/glossary.rst +++ b/Doc/glossary.rst @@ -603,7 +603,7 @@ Glossary lambda An anonymous inline function consisting of a single :term:`expression` which is evaluated when the function is called. The syntax to create - a lambda function is ``lambda [arguments]: expression`` + a lambda function is ``lambda [parameters]: expression`` LBYL Look before you leap. This coding style explicitly tests for diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst index 7fe989b9052411..6b2d6a9e0a8568 100644 --- a/Doc/reference/expressions.rst +++ b/Doc/reference/expressions.rst @@ -1613,12 +1613,12 @@ Lambdas lambda_expr_nocond: "lambda" [`parameter_list`]: `expression_nocond` Lambda expressions (sometimes called lambda forms) are used to create anonymous -functions. The expression ``lambda arguments: expression`` yields a function +functions. The expression ``lambda parameters: expression`` yields a function object. The unnamed object behaves like a function object defined with: .. code-block:: none - def (arguments): + def (parameters): return expression See section :ref:`function` for the syntax of parameter lists. Note that