Abu al-Abbas Ahmad ibn Idris. Maliki jurist of Berber origin who lived in Ayyubid and Mamluk Egypt. The greatest Maliki legal theoretician of the thirteenth century, his writings and influence on Islamic legal theory (usul al-fiqh) spread throughout the Muslim world. His insistence on the limits of law underscores the importance of nonlegal (not to be confused with illegal) considerations in determining the proper course of action, with significant implications for legal reform in the modern Islamic world. His views on the common good (maslahah) and custom provide means to accommodate the space-time differential between modern and premodern realities. The most important of his many works are Al-dhakhirah (The stored treasure), Al-furuq (Differences [between apparently identical legal precepts]), Nafais al-usul (Gems of legal theory), and Kitab al-ihkam fi tamyiz al-fatawa an al-ahkam wa tasarrufat al-qadi wa'l-imam (The book of perfecting the distinction between legal opinions, judicial decisions, and the discretionary actions of judges and caliphs).