New tests and bugs
andrei.eremeev
andrei.eremeev at oracle.com
Mon Feb 9 14:32:32 UTC 2015
Hi REPL team,
Please, find new tests here:
http://cr.openjdk.java.net/~aeremeev/forward_reference.00/
Found bugs: calling of unresolved method causes creation of temporary
variable
-> int f() { return x; }
| Declared method f, however, it cannot be invoked until variable x is
declared
-> f()
| Attempted to call f which cannot be invoked until variable x is declared.
-> /vars
| int $1 = 0
Class redeclaration changes behavior of assign variable:
assertDeclare("class A { public String toString() { return \"old\"; }
}", Declared);
assertDeclare("A a = new A();", Declared);
assertExecute1("a;", "old");
assertDeclare("class A { public String toString() { return \"new\"; }
}", Replaced);
assertExecute1("a;", "old"); <-- Expected old, but found null.
Andrei Eremeev
More information about the kulla-dev
mailing list