Using a conformal map from the unit disk to the upper half-plane that takes the upper part of the unit circle to the positive real axis, you can replace the problem by one in which g is an analytic function on the upper half-plane, continuous on the real axis and such that g(z)=1 on the positive real axis. Then apply the reflection principle, defining , to extend g to an analytic function on the cut plane . This extended function is constant on the positive real axis and hence constant everywhere.