The eminent Muslim scholar and renowned Da`iyah, Sheikh `AbdelKhaliqHasan Ash-Shareef, states: “Almighty Allah says, “Lo! Allah forgiveth not that a partner should be ascribed unto Him. He forgiveth (all) save that to whom He will.” (An-Nisaa‘ 4: 48) This is an evidence that all sins (including the non-performance of Prayer) except shirk   may be forgiven by Allah. As for the Prophet’s hadith, ‘The difference between us and them is salah. Whoever neglects it is a kafir.’, it indicates not following the command of Allah or the way of the righteous people. But if he abandons Prayer denying it as an obligation and pillar of Islam, then he is regarded as an unbeliever.

Having clarified the above, the good deeds of the one who does not perform Prayer (without denying its obligation) are acceptable in shaa‘ Allah, but he puts himself in a great danger due to abandoning Prayer.