zrax / pycdc

C++ python bytecode disassembler and decompiler
GNU General Public License v3.0
3.38k stars 645 forks source link

Wrong default function parameters decompilation #507

Open greenozon opened 3 months ago

greenozon commented 3 months ago

input sample:

def foo1(p1, p2, /, arg1=100, arg2='argos2', **kwargs):
    pass

decompiled using pycdc as:

def foo1(p1, p2, arg1, arg2 = (100, 'argos2'), **kwargs):
    pass

any clues how to fix it to the rescue?

sample files attached

sample-1.zip