private void updateReturnOp(Rop op, SourcePosition pos) {
    if (op == null) {
      throw new NullPointerException("op == null");
    }

    if (pos == null) {
      throw new NullPointerException("pos == null");
    }

    if (returnOp == null) {
      returnOp = op;
      returnPosition = pos;
    } else {
      if (returnOp != op) {
        throw new SimException("return op mismatch: " + op + ", " + returnOp);
      }

      if (pos.getLine() > returnPosition.getLine()) {
        // Pick the largest line number to be the "canonical" return.
        returnPosition = pos;
      }
    }
  }
Sets or updates the information about the return block.

@param op {@code non-null;} the opcode to use
@param pos {@code non-null;} the position to use
android/android_framework/dex-maker/src/main/java/com/android/dx/cf/code/RopperMachine.java