Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.api/src/com/oracle/truffle/api/impl/DefaultTruffleRuntime.java @ 19710:48eeda5dfdbf
Move linking of RootNode to CallTarget to ensure final semantics.
* "this" was published before complete initialization by being in the constructor.
* Make the constructor protected where possible.
author | Benoit Daloze <benoit.daloze@jku.at> |
---|---|
date | Fri, 06 Mar 2015 18:51:31 +0100 |
parents | b54b548047ac |
children |
comparison
equal
deleted
inserted
replaced
19709:678a3de139ad | 19710:48eeda5dfdbf |
---|---|
53 } | 53 } |
54 | 54 |
55 @Override | 55 @Override |
56 public RootCallTarget createCallTarget(RootNode rootNode) { | 56 public RootCallTarget createCallTarget(RootNode rootNode) { |
57 DefaultCallTarget target = new DefaultCallTarget(rootNode); | 57 DefaultCallTarget target = new DefaultCallTarget(rootNode); |
58 rootNode.setCallTarget(target); | |
58 callTargets.put(target, null); | 59 callTargets.put(target, null); |
59 return target; | 60 return target; |
60 } | 61 } |
61 | 62 |
62 public DirectCallNode createDirectCallNode(CallTarget target) { | 63 public DirectCallNode createDirectCallNode(CallTarget target) { |