Closed andrem-eberle closed 1 year ago
I am not totally sure, but this is probably better corrected in xdis, and then possibly no change is needed in this project.
I suggest looking at the recent change to xdis
to see how Python 2's "long" type was recently handled in Python 3. Probably something similar for "unicode" is needed.
This was more an xdis bug than an uncompyle6 bug. The master branch of xdis now corrects this.
:blush:
Description
Unicode strings in Python 2.7.18 are generating regular strings after decompilation.
This one might be a minor bug, and usually not an issue, but it breaks some tests in test_ast.py for the 2.7.18.
Also this one seems to include potential xdis disasm errors also, as it doesn't seem to flag the string as unicode?
How to Reproduce
Input:
run compileall & uncompyle6
Output Given
Running the first code will give:
For the uncompiled code:
Expected behavior
Should return the correct unicode form for the string.
Environment
Python 2.7.18 Ubuntu 16.0x