Why is this assumption needed in Cauchy’s theorem

complex integrationcomplex-analysis

I am studying complex analysis and Cauchy's theorem states:

Suppose that a function $f$ is analytic in a simply connected domain $D$ and that $f'$ is continuous in $D$. Then for every simple closed contour $C$ in $D$, $\oint_C f(z)dz = 0$

Next after this theorem the book presents Cauchy-Goursat theorem which states that we don't actually need $f'$ to be continuous as assumption.

My question: If it is given that function $f$ is analytic in a domain $D$ doesn't it mean that function $f$ is infinitely differentiable in that domain? Then we know that $f'$ is differentiable and so we know that $f'$ must be continuous. What I don't understand is why it is a big deal removing the assumption of continuous derivative if it is already implied by analyticity of the function. What am I missing?

Best Answer

The version I know of this theorem states only the hypothesis that $f$ has a (complex) derivative, except possibly at a finite number of points.

Furthermore, the proof that, if $f$ is holomorphic, it is infinitely differentiable depends on this theorem.