comparison graal/com.oracle.truffle.dsl.processor/src/com/oracle/truffle/dsl/processor/model/NodeData.java @ 20966:05a2b72c071f

Truffle-DSL: fixed potential non generic executes in uninitialized nodes.
author Christian Humer <christian.humer@gmail.com>
date Wed, 15 Apr 2015 13:49:38 +0200
parents 56eb34a5aa22
children 6361fa2e3321
comparison
equal deleted inserted replaced
20965:05e1ab8c5c6a 20966:05a2b72c071f
552 552
553 public int compareTo(NodeData o) { 553 public int compareTo(NodeData o) {
554 return getNodeId().compareTo(o.getNodeId()); 554 return getNodeId().compareTo(o.getNodeId());
555 } 555 }
556 556
557 public TypeMirror getGenericType(NodeExecutionData execution) {
558 return ElementUtils.getCommonSuperType(getContext(), getGenericTypes(execution));
559 }
560
557 public List<TypeMirror> getGenericTypes(NodeExecutionData execution) { 561 public List<TypeMirror> getGenericTypes(NodeExecutionData execution) {
558 List<TypeMirror> types = new ArrayList<>(); 562 List<TypeMirror> types = new ArrayList<>();
559 563
560 // add types possible through return types and evaluated parameters in execute methods 564 // add types possible through return types and evaluated parameters in execute methods
561 if (execution.getChild() != null) { 565 if (execution.getChild() != null) {