Ibn Masud was mentioned in the presence of Abdullah bin Amr, and he said, "That is a man I will never cease to love after hearing the Messenger of Allah ﷺ say, 'Learn the Quran from four men, from Ibn Masud, Salim the freed slave of Huzayfah, Ubayy bin Kaab, and Muaz bin Jabal.'"
ذكروا ابن مسعود عند عبد الله بن عمرو فقال: ذاك رجل لا أزال أحبه بعدما سمعت رسول الله ﷺ يقول: استقرؤوا القرآن من أربعة: من ابن مسعود، وسالم مولى حذيفة، وأبي بن كعب، ومعاذ بن جبل.
Bukhari narrated it in the Virtues of the Quran (4999), and Muslim in the Virtues of the Companions (2464), both from the hadith of Shuba, from Amr bin Mura, from Ibrahim, from Masruq, who mentioned it. The wording given here is Muslim's, and Bukhari's wording is similar.