blob: 4bb6b212a3f369051d706886a939d8d61e20c7b4 [file] [log] [blame]
def _GetOpList():
"""Returns list of all defined opcodes.
Does not eliminate duplicates by C{OP_ID}.
"""
return [v for v in globals().values()
if (isinstance(v, type) and issubclass(v, OpCode) and
hasattr(v, "OP_ID") and v is not OpCode and
v.OP_ID != 'OP_INSTANCE_MULTI_ALLOC_BASE')]
OP_MAPPING = dict((v.OP_ID, v) for v in _GetOpList())