Heavy fermions and superconductivity in doped cuprates