Language:
كتاب الكفالة
39  
Kafalah
(2)
Chapter: The Statement of Allah jala jalaaluhu:"... To those also with whom you have made a pledge, give them their due portion by Wasiya..."
(2)
بَابُ قَوْلِ اللَّهِ تَعَالَى: {وَالَّذِينَ عَاقَدَتْ أَيْمَانُكُمْ فَآتُوهُمْ نَصِيبَهُمْ}
Sahih al-Bukhari 2292

Narrated Sa`id bin Jubair:

Ibn `Abbas said, "In the verse: To every one We have appointed ' (Muwaliya Muwaliya means one's) heirs (4.33).' (And regarding the verse) 'And those with whom your right hands have made a pledge.' Ibn `Abbas said, "When the emigrants came to the Prophet (ﷺ) in Medina, the emigrant would inherit the Ansari while the latter's relatives would not inherit him because of the bond of brotherhood which the Prophet established between them (i.e. the emigrants and the Ansar). When the verse: 'And to everyone We have appointed heirs' (4.33) was revealed, it canceled (the bond (the pledge) of brotherhood regarding inheritance)." Then he said, "The verse: To those also to whom your right hands have pledged, remained valid regarding cooperation and mutual advice, while the matter of inheritance was excluded and it became permissible to assign something in one's testament to the person who had the right of inheriting before.

حَدَّثَنَا الصَّلْتُ بْنُ مُحَمَّدٍ، حَدَّثَنَا أَبُو أُسَامَةَ، عَنْ إِدْرِيسَ، عَنْ طَلْحَةَ بْنِ مُصَرِّفٍ، عَنْ سَعِيدِ بْنِ جُبَيْرٍ، عَنِ ابْنِ عَبَّاسٍ ـ رضى الله عنهما – ‏{‏وَلِكُلٍّ جَعَلْنَا مَوَالِيَ‏}‏ قَالَ وَرَثَةً ‏{‏وَالَّذِينَ عَقَدَتْ أَيْمَانُكُمْ‏}‏ قَالَ كَانَ الْمُهَاجِرُونَ لَمَّا قَدِمُوا الْمَدِينَةَ يَرِثُ الْمُهَاجِرُ الأَنْصَارِيَّ دُونَ ذَوِي رَحِمِهِ لِلأُخُوَّةِ الَّتِي آخَى النَّبِيُّ صلى الله عليه وسلم بَيْنَهُمْ، فَلَمَّا نَزَلَتْ ‏{‏وَلِكُلٍّ جَعَلْنَا مَوَالِيَ‏}‏ نَسَخَتْ، ثُمَّ قَالَ ‏{‏وَالَّذِينَ عَقَدَتْ أَيْمَانُكُمْ ‏}‏ إِلاَّ النَّصْرَ وَالرِّفَادَةَ وَالنَّصِيحَةَ، وَقَدْ ذَهَبَ الْمِيرَاثُ وَيُوصِي لَهُ‏.‏
Reference : Sahih al-Bukhari 2292
In-book reference : Book 39, Hadith 3
USC-MSA web (English) reference : Vol. 3, Book 37, Hadith 489
  (deprecated numbering scheme)