On Sat, Mar 26, 2022, at 14:30, Brendan Barnwell wrote:
>       To me it doesn't seem reasonable that someone would inherit from two 
> classes and want to call a method from one without even knowing that 
> there's a method name collision.  If you're going to inherit from A and 
> B, you need to know what methods they provide and you need to think 
> about the order you inherit in.

what about __init__?

you can't call A.__init__ and B.__init__ explicitly from C.__init__, because 
then both of them will call object.__init__ [maybe this is fine for object, but 
it isn't fine if you've got another class there that A and B inherit from]

It's hard enough to make signatures that this can be safely done with even 
*with* the mro, but the problem would be downright intractable without it.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/VK4X5UAZHAW575AQ5M4Q3B6J3PS7ZIIL/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to