O'Reilly logo
  • Longxiang Lyu thinks this is interesting:

The attribute x.attr here is found in superclass A, because with classic classes, the inheritance search climbs as high as it can before backing up and moving right. The full DFLR search order would visit x, D, B, A, C, and then A. For this attribute, the search stops as soon as attr is found in A, above B


Cover of Learning Python, 5th Edition


this search order is inappropriate because C has overridden the attribute while the search order still return A.