def decode(self, code_units):
    self.code_unit_idx = code_units.get_index()
    self.code_units = list()
    self.code_units.append(code_units.get_code_unit())
    op = self.get_op()
    opcode_class = self.opcode_defs[op]
    if (opcode_class is None):
        raise ValueError(('unsupported opcode %#4.4x' % swap16(self[0])))
    for i in range(1, opcode_class.num_code_units):
        self.code_units.append(code_units.get_code_unit())
    self.instruction = opcode_class(self, code_units)
def decode(self, code_units):
    self.code_unit_idx = code_units.get_index()
    self.code_units = list()
    self.code_units.append(code_units.get_code_unit())
    op = self.get_op()
    opcode_class = self.opcode_defs[op]
    if (opcode_class is None):
        raise ValueError(('unsupported opcode %#4.4x' % swap16(self[0])))
    for i in range(1, opcode_class.num_code_units):
        self.code_units.append(code_units.get_code_unit())
    self.instruction = opcode_class(self, code_units)