It is quite easy to prove, that if $f(x)$ is integrable on $[a, b]$ then $F(x)=\int_{a}^{x} f(t)\,dt$ is continuous on $[a, b]$. Also if $f(x)$ is continuous on $[a, b]$ then $F(x)$ is differentiable and $F(x)$ is an antiderivative of $f(x)$. And the antiderivative of the function is continuous by definition.
Now let's consider function:
$$ f(x)=\frac{1}{2\cos^2(x)+\sin^2(x)}$$
It is continuous on $[0, 2\pi]$ but its antiderivative is not:
$$ F(x)=\frac{1}{\sqrt{2}}\,\arctan\left(\frac{\tan(x)}{\sqrt{2}}\right) $$.
It is not continuous at $\dfrac{\pi}{2}$ or $\dfrac{3\pi}{2}$. So what am I missing? Thanks.