Skip to content

[3.13] gh-70870: Clarify dual usage of 'free variable' (GH-122545) #125088

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 8, 2024

Conversation

miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Oct 8, 2024

The term "free variable" has unfortunately become genuinely
ambiguous over the years (presumably due to the names of
some relevant code object instance attributes).

While we can't eliminate that ambiguity at this late date, we can
at least alert people to the potential ambiguity by describing
both the formal meaning of the term and the common
alternative use as a direct synonym for "closure variable".


(cherry picked from commit 2739099)

Co-authored-by: Alyssa Coghlan [email protected]
Co-authored-by: Carol Willing [email protected]


📚 Documentation preview 📚: https://cpython-previews--125088.org.readthedocs.build/

The term "free variable" has unfortunately become genuinely
ambiguous over the years (presumably due to the names of
some relevant code object instance attributes).

While we can't eliminate that ambiguity at this late date, we can
at least alert people to the potential ambiguity by describing
both the formal meaning of the term and the common
alternative use as a direct synonym for "closure variable".

---------

(cherry picked from commit 2739099)

Co-authored-by: Alyssa Coghlan <[email protected]>
Co-authored-by: Carol Willing <[email protected]>
@bedevere-app bedevere-app bot added docs Documentation in the Doc dir awaiting review labels Oct 8, 2024
@ncoghlan ncoghlan merged commit 0e0a2da into python:3.13 Oct 8, 2024
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants