R. David Murray <rdmur...@bitdance.com> added the comment: Well, then I suppose my question is why isn't __contains__ looked up? Other special methods that don't exist on Y do cause __getattr__ to be called. Why is __contains__ special? The docs for __getattr__ don't hint at this possibility either.
I think the people that understand this must have a mental model of how the interpreter looks up methods that has some pieces that are missing from mine. I guess I'd like those bits to be made explicit in the special method lookup docs, or if they are already documented somewhere, for there to be a pointer to them in the special method lookup docs. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue11988> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com