# Vanishing loop integral for continuous but not holomorphic functions on convex domains?

If $D$ is a convex domain, $\gamma$ is a rectifiable closed path and $f(z): D \to \mathbb{C}$ is continuous, then

$$\int_\gamma f(z) \mathrm{d}z = 0?$$

I don't think this is correct, since Cauchy's integral theorem needs $f$ to be holomorphic. But all the functions I tried so far that are continuous but not holomorphic ($\mathrm{Re}(z),|z|,\bar{z}$) seem to have this property. Can you give me an example of a continuous function that doesn't have this property?

A concrete example would be $f(z) = \bar z$ along the unit circle. Then $$\int_{|z|=1} \bar z\,dz = \int_{|z|=1} \frac{z\bar z}{z}\,dz = \int_{|z|=1} \frac{1}{z}\,dz = 2\pi i.$$
In fact, if $f$ is continuous (on a simply connected domain) a necessary and sufficient condition that $f$ is holomorphic is that the integral along every closed curve vanishes. So, if you take any non-holomorphic, but continuous $f$, it is possible to find such a curve.
• Apparently I made a mistake, when checked $f(z) = \bar z$ before I posted on MSE. Thanks! Aug 17, 2015 at 9:23