view graal/com.oracle.truffle.sl.test/tests/DefineFunction.sl @ 15725:ef6b8d1898e6

Add resolved receiver type to ResolvedJavaMethod.isInVirtualMethodTable in order to be able to do vtable-calls for miranda and default methods
author Gilles Duboscq <duboscq@ssw.jku.at>
date Sat, 17 May 2014 14:57:58 +0200
parents b16ec83edc73
children
line wrap: on
line source

function foo() {
  println(test(40, 2));
}

function main() {
  defineFunction("function test(a, b) { return a + b; }");
  foo();

  defineFunction("function test(a, b) { return a - b; }");
  foo();
}