Sunan an-Nasa'i, Volume 3, Book 21, Hadith 1954 (DarusSalam)

It was narrated that Ibn 'Abbas said: "The Messenger of Allah was asked about he children of the idolators and he said: 'Allah knows best what they would have done."'

أَخْبَرَنِي مُجَاهِدُ بْنُ مُوسَى، عَنْ هُشَيْمٍ، عَنْ أَبِي بِشْرٍ، عَنْ سَعِيدِ بْنِ جُبَيْرٍ، عَنِ ابْنِ عَبَّاسٍ، قَالَ سُئِلَ النَّبِيُّ صلى الله عليه وسلم عَنْ ذَرَارِيِّ الْمُشْرِكِينَ فَقَالَ ‏ "‏ اللَّهُ أَعْلَمُ بِمَا كَانُوا عَامِلِينَ ‏" ‏ ‏.‏

sunnah.com