bpo-39737: Remove code repitition in list_richcompare (GH-18638)

I may speed up list comparison on some platforms.
1 file changed