What did the Prophet Muhammad (peace be upon him) advise for someone who fasts continuously and prays all night?
  Abdu'llah b. 'Amr b. 'As (Allah be pleased with them) reported:                      It was conveyed to the Apostle of Allah (may peace be upon him) that I observe fast succes- sively and pray during the whole night. He sent for me or I met him and he (the Holy Prophet) said: It has been conveyed to me that you observe fast continuously and do not break it and pray during the whole night. Don't do that. for there is share for your eyes, share for your own self, share for your family; so observe fast and break it, pray and sleep and observe fast for one day during the ten days, and there is a reward for you (for other) nine (days besides the tenth day of the fast). I said: Apostle of Allah, I find myself more powerful than this. He said: Then observe the fast of David (peace be upon him). He ('Amr) said: Apostle of Allah, how did David observe fast? He (the Holy Prophet) said: He used to fast one day and break it on the other day, and he did not run (from the battlefield) as he encountered (the enemy). He said: Apostle of Allah, who can guarantee this for me (will I also encounter the enemy dauntlessly)? 'Ata', the narrator of the hadith, said: I do not know how there (crept in) the matter of perpetual fast. The Apostle of Allah (may peace be upon him), however, said: He who observed perpetual fast did not fast at all; he who observed perpetual fast did not fast at all, he who observed perpetual fast did not fast at all.