What warning does a Prophet of God give about being learned?

2 Nephi 9:28-29


2 Nephi 9:28-29
28. O that cunning plan of the evil one! O the vainness and the frailties, and the foolishness of men! When they are learned they think they are wise and they harken not unto the counsel of God, for they set it aside, supposing they know of themselves, wherefore, their wisdom is foolishness and it profiteth them not. And they shall perish. 29. But to be learned is good if they harken unto the counsels of God.