# HG changeset patch # User Paul Boddie # Date 1100219254 -3600 # Node ID 49aa59d86e5c4d8741cd92f805e91a462b536f3b # Parent 630f6b688af07126eb7a177c01138b3e7e22a3df Added better tracing of dispatch behaviour. diff -r 630f6b688af0 -r 49aa59d86e5c tests/DispatchTest.java --- a/tests/DispatchTest.java Thu Nov 11 22:59:18 2004 +0100 +++ b/tests/DispatchTest.java Fri Nov 12 01:27:34 2004 +0100 @@ -30,12 +30,16 @@ this.b = b; } + // The ordering of the methods probably should not prevent the most specific + // method from being chosen, but this happens with a linear search of + // appropriate methods. + public int test(DispatchInterface obj) { return obj.test(); } public int test(DispatchClass1 obj) { - return obj.test(); + return obj.test() + 10; } public int testTest(DispatchInterface obj) {