Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
stack_effect = -1
class BINARY_RSHIFT(OpCode):
__slots__ = ()
code = 63
stack_effect = -1
class BINARY_AND(OpCode):
__slots__ = ()
code = 64
stack_effect = -1
class BINARY_XOR(OpCode):
__slots__ = ()
code = 65
stack_effect = -1
class BINARY_OR(OpCode):
__slots__ = ()
code = 66
stack_effect = -1
class INPLACE_POWER(OpCode):
__slots__ = ()
code = 67
stack_effect = -1
def __init__(self, arg=_no_arg, **kw):
if arg is not _no_arg:
self.arg = arg
OpCode.__init__(self, **kw)
stack_effect = -1
class BINARY_MULTIPLY(OpCode):
__slots__ = ()
code = 20
stack_effect = -1
class BINARY_MODULO(OpCode):
__slots__ = ()
code = 22
stack_effect = -1
class BINARY_ADD(OpCode):
__slots__ = ()
code = 23
stack_effect = -1
class BINARY_SUBTRACT(OpCode):
__slots__ = ()
code = 24
stack_effect = -1
class BINARY_SUBSCR(OpCode):
__slots__ = ()
code = 25
stack_effect = -1
stack_effect = -1
class INPLACE_MODULO(OpCode):
__slots__ = ()
code = 59
stack_effect = -1
class STORE_SUBSCR(OpCode):
__slots__ = ()
code = 60
stack_effect = -3
class DELETE_SUBSCR(OpCode):
__slots__ = ()
code = 61
stack_effect = -2
class BINARY_LSHIFT(OpCode):
__slots__ = ()
code = 62
stack_effect = -1
class BINARY_RSHIFT(OpCode):
__slots__ = ()
code = 63
stack_effect = -1
stack_effect = 0
class DUP_TOP(OpCode):
__slots__ = ()
code = 4
stack_effect = 1
class DUP_TOP_TWO(OpCode):
__slots__ = ()
code = 5
stack_effect = 2
class NOP(OpCode):
__slots__ = ()
code = 9
stack_effect = 0
class UNARY_POSITIVE(OpCode):
__slots__ = ()
code = 10
stack_effect = 0
class UNARY_NEGATIVE(OpCode):
__slots__ = ()
code = 11
stack_effect = 0
stack_effect = -1
class INPLACE_AND(OpCode):
__slots__ = ()
code = 77
stack_effect = -1
class INPLACE_XOR(OpCode):
__slots__ = ()
code = 78
stack_effect = -1
class INPLACE_OR(OpCode):
__slots__ = ()
code = 79
stack_effect = -1
class BREAK_LOOP(OpCode):
__slots__ = ()
code = 80
stack_effect = 0
if sys.version_info[:2] < (3, 5):
class WITH_CLEANUP(OpCode):
__slots__ = ()
code = 81
stack_effect = -1 # XXX: Sometimes more
stack_effect = 1
class DUP_TOP_TWO(OpCode):
__slots__ = ()
code = 5
stack_effect = 2
class NOP(OpCode):
__slots__ = ()
code = 9
stack_effect = 0
class UNARY_POSITIVE(OpCode):
__slots__ = ()
code = 10
stack_effect = 0
class UNARY_NEGATIVE(OpCode):
__slots__ = ()
code = 11
stack_effect = 0
class UNARY_NOT(OpCode):
__slots__ = ()
code = 12
stack_effect = 0
self.jabs = jabs
ArgOpCode.__init__(self, **kw)
# `stack_effect` values and algorithms to calculate it are taken from
# 'Python/compile.c' opcode_stack_effect() function.
if sys.version_info[:2] < (3, 3):
# STOP_CODE has been removed in 3.3
class STOP_CODE(OpCode):
__slots__ = ()
code = 0
stack_effect = 0
class POP_TOP(OpCode):
__slots__ = ()
code = 1
stack_effect = -1
class ROT_TWO(OpCode):
__slots__ = ()
code = 2
stack_effect = 0
class ROT_THREE(OpCode):
__slots__ = ()
code = 3
stack_effect = 0
stack_effect = -1
class INPLACE_MULTIPLY(OpCode):
__slots__ = ()
code = 57
stack_effect = -1
class INPLACE_MODULO(OpCode):
__slots__ = ()
code = 59
stack_effect = -1
class STORE_SUBSCR(OpCode):
__slots__ = ()
code = 60
stack_effect = -3
class DELETE_SUBSCR(OpCode):
__slots__ = ()
code = 61
stack_effect = -2
class BINARY_LSHIFT(OpCode):
__slots__ = ()
code = 62
stack_effect = -1
stack_effect = 0
class UNARY_POSITIVE(OpCode):
__slots__ = ()
code = 10
stack_effect = 0
class UNARY_NEGATIVE(OpCode):
__slots__ = ()
code = 11
stack_effect = 0
class UNARY_NOT(OpCode):
__slots__ = ()
code = 12
stack_effect = 0
class UNARY_INVERT(OpCode):
__slots__ = ()
code = 15
stack_effect = 0
class BINARY_POWER(OpCode):
__slots__ = ()
code = 19
stack_effect = -1