Skip to content

Commit 51934e0

Browse files
committed
Add explanation of broken test
1 parent cad53c2 commit 51934e0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/snippets/class.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,9 @@ def b():
175175
A.b()
176176

177177
# TODO: uncomment once free vars/cells are working
178+
# The symboltable sees that b() is referring to a in the nested scope,
179+
# so it marks it as non local. When it's executed, it walks up the scopes
180+
# and still finds the a from the class scope.
178181
# a = 1
179182
# def nested_scope():
180183
# a = 2

0 commit comments

Comments
 (0)