Chiral Potts model as a descendant of the six-vertex model