When the function is still bounded/the limit at point of discontinuity exists, e.g for f(x) = (x-1)(x+2)/(x-1), l simplifies to x-2 , but discontinuous and undefined at x=1, so could you then evaluate the definite integral from say 0 to 2 (or really any finite interval across the point at x = 1? Thanks'
If the discontinuity occurs at, say, x = p, then integrate from a to p-eps, and add to the integral from p+eps to b, where a < p, b > p and eps is very small. If possible, do the integration symbolically, then take the limits of the results as eps tends to zero.
Incidentally, your f(x) example is continuous at x = 1: plot it to see!