Hello, I used http://python-history.blogspot.com/2010/06/method-resolution-order.html and https://www.python.org/download/releases/2.3/mro/ as the reference, but it doesn't explain MRO in the following example (python3.4):
~~~~ class User: def __str__(self): return "User.__str__" def append(self, a): print("User", a) class C(list, User): pass t = C([1, 2, 3]) print(t) t.append(10) print(t) print(t[-1]) ~~~~ The output is: ===== User.__str__ User.__str__ 10 ===== >From the output, "User" class as expected does not override list.append(), but does override list.__str__(). Is this behavior documented somewhere (complete arrangement)? What's the rationale behind it? I need this info to implement MRO in an alternative Python implementation (MicroPython). Thanks, Paul mailto:pmis...@gmail.com _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com