Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.codegen.processor/src/com/oracle/truffle/codegen/processor/node/NodeParser.java @ 9224:b69312e4eceb
Minor fix for private template types.
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Sat, 20 Apr 2013 12:22:54 +0200 |
parents | 97ad6d3e7557 |
children | 9d29e5aa54d2 |
comparison
equal
deleted
inserted
replaced
9223:5f7f0d3e3638 | 9224:b69312e4eceb |
---|---|
126 // generated nodes should not get called again. | 126 // generated nodes should not get called again. |
127 return null; | 127 return null; |
128 } | 128 } |
129 | 129 |
130 AnnotationMirror methodNodes = Utils.findAnnotationMirror(processingEnv, templateType, NodeClass.class); | 130 AnnotationMirror methodNodes = Utils.findAnnotationMirror(processingEnv, templateType, NodeClass.class); |
131 | |
132 if (methodNodes == null && !Utils.isAssignable(templateType.asType(), context.getTruffleTypes().getNode())) { | 131 if (methodNodes == null && !Utils.isAssignable(templateType.asType(), context.getTruffleTypes().getNode())) { |
133 return null; // not a node | 132 return null; // not a node |
134 } | |
135 | |
136 if (templateType.getModifiers().contains(Modifier.PRIVATE)) { | |
137 // TODO error message here!? | |
138 return null; // not visible, not a node | |
139 } | 133 } |
140 | 134 |
141 List<TypeElement> lookupTypes = findSuperClasses(new ArrayList<TypeElement>(), templateType); | 135 List<TypeElement> lookupTypes = findSuperClasses(new ArrayList<TypeElement>(), templateType); |
142 Collections.reverse(lookupTypes); | 136 Collections.reverse(lookupTypes); |
143 | 137 |