Muwatta Malik, Book 36, Hadith 1457 (In-Book)

Malik related to me that he heard that a man of the Ansar from the tribe of Banu al-Harith ibn al-Khazraj, gave sadaqa to his parents and then they died. Their son inherited the property he had given them and it was palm-trees. He asked the Messenger of Allah, may Allah bless him and grant him peace, about it and he said, "You are rewarded for your sadaqa, and take it as your inheritance."

وَحَدَّثَنِي مَالِكٌ، أَنَّهُ بَلَغَهُ أَنَّ رَجُلاً، مِنَ الأَنْصَارِ مِنْ بَنِي الْحَارِثِ بْنِ الْخَزْرَجِ تَصَدَّقَ عَلَى أَبَوَيْهِ بِصَدَقَةٍ فَهَلَكَا فَوَرِثَ ابْنُهُمَا الْمَالَ وَهُوَ نَخْلٌ فَسَأَلَ عَنْ ذَلِكَ رَسُولَ اللَّهِ صلى الله عليه وسلم فَقَالَ ‏ "‏ قَدْ أُجِرْتَ فِي صَدَقَتِكَ وَخُذْهَا بِمِيرَاثِكَ ‏" ‏ ‏.‏

sunnah.com

also referenced under: Book 36, Hadith 54 (USC-MSA)