$\frac{-x+2}{x^{2}+x-2}=\frac{-4}{3(x+2)}+\frac{1}{3(x-1)}$
Wolphram Alpha states that one can do this with long division, I cannot immediately realize it. Could someone show the trick to simplify the LHD to RHD?
Context: Trying to compute $\int \frac{x^2}{x^2+x-2}\,dx$