def small_integer_from_opcode(opcode)
      return 0  if opcode == "".b # OP_O
      return 0  if opcode == OP_0
      return -1 if opcode == OP_1NEGATE
      if opcode >= OP_1 && opcode <= OP_16
        return opcode - (OP_1 - 1)
      end
      return nil
    end
def small_integer_from_opcode(opcode)
      return 0  if opcode == "".b # OP_O
      return 0  if opcode == OP_0
      return -1 if opcode == OP_1NEGATE
      if opcode >= OP_1 && opcode <= OP_16
        return opcode - (OP_1 - 1)
      end
      return nil
    end
Converts opcode OP_<N> or OP_1NEGATE to an integer value.
 If incorrect opcode is given, nil is returned.