Skip to content

Conversation

whoami730
Copy link
Contributor

@whoami730 whoami730 commented Jul 13, 2025

Adds support for below opcodes with tests -
[x] LOAD_FAST_CHECK
[x] CALL_INTRINSIC_1 - INTRINSIC_LIST_TO_TUPLE
[x] CALL_FUNCTION_EX

Updates existing LIST_EXTEND implementation with tests

@whoami730
Copy link
Contributor Author

Thanks for the review @zrax , I have updated the PR.

@dasabi45
Copy link

Source Generated with Decompyle++

File: QMXQ.pyc (Python 3.13)

Unimplemented function 2Unimplemented function 2Unimplemented function 2Unsupported opcode: MAKE_FUNCTION (122)
import pygame
import random
import copy
import json
import os
import time
import math
from OpenGL.GL.shaders import compileProgram, compileShader
import numpy
import csv
import locale
import sys
dise = (45, 50, 50)
xitong = sys.platform

WARNING: Decompyle incomplete

I encountered this problem, how can I solve it?

@whoami730
Copy link
Contributor Author

Below are the errors @dasabi45

Unimplemented function 2
Unimplemented function 2
Unimplemented function 2
Unsupported opcode: MAKE_FUNCTION (122)

I believe function 2 is INTRINSIC_IMPORT_STAR. You need to add implementation for whatever's missing... I believe all you need to do here is create an ASTImport object or something...

@whoami730
Copy link
Contributor Author

Hi @zrax any updates here would be appreciated, thanks!

@NyaMisty
Copy link

Sir, I've encoutered an C++ exception

            'type': self.upgrade_type })


    def terminate(self, error = (False,)):
terminate called after throwing an instance of 'std::bad_cast'
  what():  std::bad_cast

Program received signal SIGABRT, Aborted.
__pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
warning: 44     ./nptl/pthread_kill.c: No such file or directory
(gdb) bt
#0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
#1  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
#3  0x00007ffff7b3b27e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#4  0x00007ffff7b1e8ff in __GI_abort () at ./stdlib/abort.c:79
#5  0x00007ffff7ddbff5 in ?? () from /lib/x86_64-linux-gnu/libstdc++.so.6
#6  0x00007ffff7df10da in ?? () from /lib/x86_64-linux-gnu/libstdc++.so.6
#7  0x00007ffff7ddba55 in std::terminate() () from /lib/x86_64-linux-gnu/libstdc++.so.6
#8  0x00007ffff7df1391 in __cxa_throw () from /lib/x86_64-linux-gnu/libstdc++.so.6
#9  0x0000555555587e26 in PycRef<ASTBlock>::cast<ASTContainerBlock> (this=0x7fffffffb5a0) at /mnt/d/Workspaces/new_pycdc/pycdc/pyc_object.h:85
#10 0x0000555555563845 in BuildFromCode (code=..., mod=0x7fffffffcbe0) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:857
#11 0x000055555557f813 in decompyle (code=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3559
#12 0x000055555557b0ef in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3153
#13 0x000055555557cdbe in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3383
#14 0x000055555557a95b in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3094
#15 0x0000555555580910 in decompyle (code=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3646
#16 0x000055555557b0ef in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3153
#17 0x000055555557d1ab in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3409
#18 0x000055555557a95b in print_src (node=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3094
#19 0x0000555555580910 in decompyle (code=..., mod=0x7fffffffcbe0, pyc_output=...) at /mnt/d/Workspaces/new_pycdc/pycdc/ASTree.cpp:3646
#20 0x000055555555c0e5 in main (argc=2, argv=0x7fffffffcfb8) at /mnt/d/Workspaces/new_pycdc/pycdc/pycdc.cpp:97

@whoami730
Copy link
Contributor Author

@NyaMisty can you please share the pyc file? it's hard to investigate without the file.

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.

4 participants