]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
GvR pointed out that only enclosing function bodies are part of nested scopes.
authorRaymond Hettinger <python@rcn.com>
Wed, 7 Aug 2002 20:23:00 +0000 (20:23 +0000)
committerRaymond Hettinger <python@rcn.com>
Wed, 7 Aug 2002 20:23:00 +0000 (20:23 +0000)
Doc/tut/tut.tex

index 655cf973812a8aae8d61cad8f418c91455f6a4ee..e1eb84d08ef4638a516c397077ad27b119acd62b 100644 (file)
@@ -3510,11 +3510,11 @@ the namespace.
 Although scopes are determined statically, they are used dynamically.
 At any time during execution, there are at least three nested scopes whose
 namespaces are directly accessible: the innermost scope, which is searched
-first, contains the local names; the namespaces of any enclosing code
-blocks (a module, function, or class definition) which are searched starting
-with the nearest enclosing scope; the middle scope, searched next, contains
-the current module's global names; and the outermost scope (searched last)
-is the namespace containing built-in names.
+first, contains the local names; the namespaces of any enclosing
+functions, which are searched starting with the nearest enclosing scope;
+the middle scope, searched next, contains the current module's global names;
+and the outermost scope (searched last) is the namespace containing built-in
+names.
 
 If a name is declared global, then all references and assignments go
 directly to the middle scope containing the module's global names.