The Prophet ﷺ was asked about the children of the polytheists, and he replied, "Allah knows best what they would have done."
أخبرني مجاهد بن موسى عن هشيم عن أبي بشر عن سعيد بن جبير
سئل النبي ﷺ عن ذراري المشركين فقال الله أعلم بما كانوا عاملين
[Sahih] See the previous hadith. It is also in Kubra, no. 2079.