I guess there is a similar concern here as at https://github.com/sympy/sympy/pull/2481. Could some pathological input cause an OverflowError here? I don't see any reason to not just use rationals for prec and eps.