SJB, I never said Aquinas was a heretic. That judgment has been made in the negative by the external forum, by way of his canonization. That doesn't mean that he was right about all of his teachings, though.
And as for the others, I don't yet know of any heresies by Pius XI, though he was subject to the publicly heretical Benedict XV, as was Pius XII, who was also publicly heretical. Their works speak for themselves, for those with eyes to see and ears to hear.