docs: static long checkedAdd(long x, long y) {
      BigInteger sum = BigInteger.valueOf(x).add(BigInteger.valueOf(y));
      if (sum.compareTo(MAX_LONG_VALUE) > 0 || sum.compareTo(MIN_LONG_VALUE) < 0) {
        throw new ArithmeticException("Long sum overflow: x=" + x + ", y=" + y);
      }
      return x + y;
    }