In addition to this previous post (linked) please see what the scholars of the Ahlus Sunnah say:
وقال أهل السنة والجماعة: الكافر إذا أسلم كان كافراً إلى وقت إسلامه، وإنما صار مسلماً بإسلامه إلا أنه غفر له ما قد سلف. والمسلم إذا كفر كان مسلماً إلى ذلك الوقت، إلا أنه حبط عمله
أبو الليث نصر بن محمد بن أحمد بن إبراهيم السمرقندي
And the Ahlus Sunnah wal Jama’ah have said: A kafir, if he becomes Muslim, was a kafir until the time of his acceptance of Islam, and indeed he became a Muslim due to his Islam, so much that all that he did in the past is forgiven to him; and a Muslim, if he disbelieves, was a Muslim only until such time, having destroyed all his past deeds [due to his committing kufr].
Bahr-ul-‘Uloom of Imam Abul Layth Al-Samarqandi (d. 373 Hijri), under the tafsiir of verse 2:34
The munaafiqiin love to sow doubts in the hearts of Muslims by preventing them from calling the christians, jews, buddhists, and others outside of Islam as kafirs. It hurts these filthy munaafiqiin greatly when Muslims refute the filthy idiotic religions and doctrines of their kafir brothers and sisters, like the filthy doctrine of trinity, and it hurts them greatly when Muslims tell their kafir brothers and sisters of Allah’s punishment upon them should they leave the world as kafirs.
The Muslims’ maxim is very simple – as soon as someone becomes a Muslim, he/she is our esteemed brother/sister.
The zanaadiq cause confusion by trying to talk about “Allah’s judgment” upon a person; that perhaps he will die a Muslim in the future, or that perhaps he accepted Islam just before he met the Angel of Death and no one witnessed him pronouncing the shahadah, and so in Allah’s judgment his state is not kafir, etc.
Try this test with such people. When ever they talk to you in this manner, tell them: “We also do not know Allah’s judgement upon YOU. So we restrain from calling you Muslim and treating you like our brother. Maybe you will become a defiant kafir and a sworn enemy of Islam just before you witness the Angel of Death, and in reality you’re a damned hypocrite and an infidel in Allah’s judgment who is headed for a never ending session of having his goatee peeled off and his head bludgeoned in the lowest pits of hellfire.”
Our job in this world is not to guess upon “what could have been” or “what may be in the future”, much less speculating on what Allah’s judgement is. We are only commanded to act upon the apparent in real time in light of the Shari’ah.
And success isn’t but by Allah’s granting.