diff options
author | Guido van Rossum <guido@python.org> | 2001-07-06 20:26:31 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2001-07-06 20:26:31 (GMT) |
commit | 4269601f5c57a16bce656efd4576c86b054a95cd (patch) | |
tree | 68747dbb091c4a969f973880fe34a2cf5ae55bed /Tools/compiler | |
parent | ab1df4fe88bc208cc917e5d6dede0ab8f758a342 (diff) | |
download | cpython-4269601f5c57a16bce656efd4576c86b054a95cd.zip cpython-4269601f5c57a16bce656efd4576c86b054a95cd.tar.gz cpython-4269601f5c57a16bce656efd4576c86b054a95cd.tar.bz2 |
Amazing. A very subtle change in policy in descr-branch actually
found a bug here. Here's the deal:
Class PyShell derives from class OutputWindow. Method PyShell.close()
wants to invoke its parent method, but because PyShell long ago was
inherited from class PyShellEditorWindow, it invokes
PyShelEditorWindow.close(self). Now, class PyShellEditorWindow itself
derives from class OutputWindow, and inherits the close() method from
there without overriding it. Under the old rules,
PyShellEditorWindow.close would return an unbound method restricted to
the class that defined the implementation of close(), which was
OutputWindow.close. Under the new rules, the unbound method is
restricted to the class whose method was requested, that is
PyShellEditorWindow, and this was correctly trapped as an error.
Diffstat (limited to 'Tools/compiler')
0 files changed, 0 insertions, 0 deletions