Skip to content
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

Handling of name collisions #71

Open
ekzhang opened this issue Jan 7, 2018 · 0 comments
Open

Handling of name collisions #71

ekzhang opened this issue Jan 7, 2018 · 0 comments

Comments

@ekzhang
Copy link

ekzhang commented Jan 7, 2018

It seems that certain variable names can end up in name collisions in the generated code. For example, the code

def f(__print):
    print __print
    return __print * 4
y = f(5)
print y

is turned into the one-line code

(lambda __g, __print: [[(__print(y), None)[1] for __g['y'] in [(f(5))]][0] for __g['f'], f.__name__ in [(lambda __print: (lambda __l: [(__print(__l['__print']), (__l['__print'] * 4))[1] for __l['__print'] in [(__print)]][0])({}), 'f')]][0])(globals(), __import__('__builtin__').__dict__['print'])

which gives a TypeError when run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant