| 1 | #!/usr/bin/env python2 |
| 2 | """ |
| 3 | load_make_closure.py - A generator expression should not generate the |
| 4 | LOAD_CLOSURE or MAKE_CLOSURE bytecodes. |
| 5 | """ |
| 6 | # Copied from core/braces.py |
| 7 | # It erroneously generaets a closure because of: |
| 8 | # co_freevars: ('parts_list',) |
| 9 | # |
| 10 | # In CPython that list is empty. |
| 11 | def BraceExpandWords(words): |
| 12 | parts_list = [] |
| 13 | print(p for p in parts_list if len(p) > 2) |