Commit cc29641f authored by Jeremy Hylton's avatar Jeremy Hylton

Update programmer's note on nested functions.

parent b36bd4fe
...@@ -389,11 +389,11 @@ form. The ``\keyword{def}'' form is actually more powerful since it ...@@ -389,11 +389,11 @@ form. The ``\keyword{def}'' form is actually more powerful since it
allows the execution of multiple statements. allows the execution of multiple statements.
\indexii{lambda}{form} \indexii{lambda}{form}
\strong{Programmer's note:} a ``\code{def}'' form executed inside a \strong{Programmer's note:} Functions are first-class objects. A
function definition defines a local function that can be returned or ``\code{def}'' form executed inside a function definition defines a
passed around. The semantics of name resolution in the nested local function that can be returned or passed around. Free variables
function will change in Python 2.2. See the appendix for a used in the nested function can access the local variables of the
description of the new semantics. function containing the def. See section \ref{naming} for details.
\section{Class definitions\label{class}} \section{Class definitions\label{class}}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment