Fiqh-us-Sunnah Volume 2, Supererogatory Prayer, Fiqh 2.095.

Section : Intentionally eating or drinking invalidates the salah.

Ibn al-Munzhir says: “The people of knowledge agree that if one intentionally eats or drinks during a fard salah, he is to repeat the salah. The same is the case with nawafil according to the majority of scholars as what invalidates an obligatory (fard) prayer also invalidates a voluntary (nafl) prayer.”