(18) بَاب لَا تَقُومُ السَّاعَةُ حَتَّى يَمُرَّ الرَّجُلُ بِقَبْرِ الرَّجُلِ فَيَتَمَنَّى أَنْ يَكُونَ مَكَانَ الْمَيِّتِ مِنْ الْبَلَاءِ
Abu Sa`id Khudri reported:
One who is better than I informed me, that Allah's Messenger (ﷺ) said to `Ammar as he was digging the ditch (on the ocassion of the Battle of the Ditch) wiping over his head: O son of Summayya, you will be involved in trouble and a group of the rebels would kill you.
Reference: Sahih Muslim 2915 a
In-book reference: Book 54, Hadith 86
USC-MSA web (English) reference(deprecated numbering scheme): Book 41, Hadith 6966