You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 16:59:52 +08:00
Fix --linemap option, yet again.
This commit is contained in:
@@ -121,7 +121,7 @@ def decompile(
|
|||||||
if isinstance(mapstream, str):
|
if isinstance(mapstream, str):
|
||||||
mapstream = _get_outstream(mapstream)
|
mapstream = _get_outstream(mapstream)
|
||||||
|
|
||||||
debug_opts = {"asm": showasm, "tree": showast, "grammar": showgrammar}
|
debug_opts = {"asm": showasm, "tree": showast, "grammar": grammar}
|
||||||
|
|
||||||
deparsed = deparse_code_with_map(
|
deparsed = deparse_code_with_map(
|
||||||
co=co,
|
co=co,
|
||||||
@@ -347,9 +347,7 @@ def main(
|
|||||||
sys.stdout.write(f"\n{str(e)}\n")
|
sys.stdout.write(f"\n{str(e)}\n")
|
||||||
if str(e).startswith("Unsupported Python"):
|
if str(e).startswith("Unsupported Python"):
|
||||||
sys.stdout.write("\n")
|
sys.stdout.write("\n")
|
||||||
sys.stderr.write(
|
sys.stderr.write(f"\n# Unsupported bytecode in file {infile}\n# {e}\n")
|
||||||
f"\n# Unsupported bytecode in file {infile}\n# {e}\n"
|
|
||||||
)
|
|
||||||
else:
|
else:
|
||||||
if outfile:
|
if outfile:
|
||||||
outstream.close()
|
outstream.close()
|
||||||
|
Reference in New Issue
Block a user