Is there a non-continuous Riemann integrable function with an anti-derivative? Is there a function $f:[a,b]\rightarrow\mathbb{R}$ (for real $a&lt;b$) which is Riemann integrable and has an antiderivative in $[a,b]$, but is not continuous?
Consider:

$$f(x) = \begin{cases} 2x \sin \left( \frac1{x} \right) - \cos \left( \frac1{x} \right), x \neq 0 \\ 0, x=0 \end{cases}$$

$f$ is Riemann integrable on $[-1,1]$ (by Lebesgue's theorem for Riemann integrals, for instance), and has the antiderivative:

$$F(x) = \begin{cases} x^2 \sin \left( \frac1{x} \right), x \neq 0 \\ 0, x = 0 \end{cases}$$
Assume we have a function $g(x)$ is continuous and Riemann integrable with an antiderivative. Let's define another a new function $$f(x)= \begin{cases} g(x), x \neq c \\ \neq g(c), x = c \end{cases}$$ 

The new function $f(x)$ is not continuous but it is Riemann integrable and has the same antiderivative as $g(x)$.