view graal/com.oracle.truffle.sl.test/tests/DefineFunction.sl @ 19891:aa66d0a6f9dc

MethodHandleNode: record unique concrete method assumptions
author Andreas Woess <andreas.woess@oracle.com>
date Tue, 17 Mar 2015 15:36:09 +0100
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();
}