New submission from Peter Bauer <p-bauer...@t-online.de>:

In the fourth paragraph, the sentence 

"Thus, global variables cannot be directly assigned a value within a function 
(unless named in a global statement)"

should somehow be extended to mention the nonlocal-statements:

Thus, global variables or variables of enclosing functions cannot be directly 
assigned a value within a function (unless named in a global statement (for 
global variables) or named in a nonlocal statement (for variables of enclosing 
functions)

----------
assignee: docs@python
components: Documentation
messages: 340963
nosy: docs@python, pbhd0815
priority: normal
severity: normal
status: open
title: "4.6. Defining Functions" should mention nonlocal
type: enhancement
versions: Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue36739>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to