وَاعْلَمْ أَنَّ إِعْرَابَ «غَيْرٍ» كَإِعْرَابِ الْمُسْتَثْنَى بِـ«إِلَّا».
Translation: Know that ghayr itself takes the case pattern of an exception introduced by illā.
The author states that ghayr itself takes the case corresponding to an exception with illā.
«جَاءَنِي الْقَوْمُ غَيْرَ زَيْدٍ»: ghayra is accusative; Zaydin is genitive.
«مَا جَاءَنِي أَحَدٌ غَيْرُ زَيْدٍ»: ghayru can be nominative badal, while Zaydin remains genitive in the iḍāfa.
These are two different grammatical roles and two different cases.