This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author mdk
Recipients docs@python, marco.buttu, mdk
Date 2016-12-02.14:21:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1480688500.79.0.818214035028.issue28853@psf.upfronthosting.co.za>
In-reply-to
Content
Hi, thanks for reporting,

Variables are defined in python docs¹ by:

> If a name is bound in a block, it is a local variable of that block, unless declared as nonlocal or global. If a name is bound at the module level, it is a global variable. (The variables of the module code block are local and global.) If a variable is used in a code block but not defined there, it is a free variable.

According to this definition, global variables used in a code block are free variable, is this intentional? I think so, but can't be sure, maybe someone is seeing this as "globals are NOT free variables", in this case, this definition should probably be enhanced.

If I'm right, maybe we should just change "Free variables are returned"… to "Non-global free variables are returned"…?
History
Date User Action Args
2016-12-02 14:21:40mdksetrecipients: + mdk, docs@python, marco.buttu
2016-12-02 14:21:40mdksetmessageid: <1480688500.79.0.818214035028.issue28853@psf.upfronthosting.co.za>
2016-12-02 14:21:40mdklinkissue28853 messages
2016-12-02 14:21:40mdkcreate