Skip to content

Change dis.dis to take strings to decompile #2054

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 3 commits into from
Aug 1, 2020

Conversation

BolunThompson
Copy link
Contributor

Currently, the dis function from the dis module can only take functions to decompile. This changes it so that strings, when passed to dis, are compiled then disassembled.
This also includes tests for the dis module.

Currently, the dis module's dis function only accepts functions tp
decompile. This adds support for disassembling strings. It does this by
compiling the string, then disassembling compiled output.
As of this commit, these tests fail.
This was chaned because stdout is being written to by rust code, which
currently can't be redirected by reassigning sys.stdout. This caused the
tests to fail because they couldn't see the output of what was being tested.
@BolunThompson BolunThompson changed the title Have dis.dis take strings to decompile Change dis.dis to take strings to decompile Aug 1, 2020
@youknowone youknowone merged commit 55e97af into RustPython:master Aug 1, 2020
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

Successfully merging this pull request may close these issues.

2 participants