And Allah Most High says:
“Permission to fight has been given to those who are being fought, because they have been wronged. Indeed, Allah is surely able to grant them victory—those who were driven from their homes without right, merely for saying, ‘Our Lord is Allah.’” [Surah al-Hajj: 39, 40]
And He says:
“Allah only forbids you from taking as allies those who fought you because of your religion, drove you from your homes, and supported your expulsion.” [Surah al-Mumtahanah: 9]
This is because they prevented them from remaining in Mecca while retaining their faith, and they could not abandon their faith. Thus, they drove them out (* if they were believers. This shows that the disbelievers drove out his companion just as they drove him out, and the disbelievers drove out only *) (1) their enemies, not those among them who were disbelievers.
This shows that his companionship was founded on loyalty and agreement in faith, not companionship accompanied by disbelief.
If it is said: This shows that he outwardly expressed agreement, but some who were inwardly hypocrites also outwardly expressed agreement with him. They may also be included under the term “companions,” as in his statement when permission was sought to kill some of the hypocrites:
“People must not say that Muhammad kills his companions.” (2)
This shows that people did include hypocrites under this term.