Mercurial > hg > graal-jvmci-8
changeset 11465:3d618420a4b6
Truffle-DSL: minor cleanup.
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Thu, 29 Aug 2013 14:28:43 +0200 |
parents | e55e24cc3e7b |
children | 4830676526e3 |
files | graal/com.oracle.truffle.dsl.processor/src/com/oracle/truffle/dsl/processor/node/NodeMethodParser.java |
diffstat | 1 files changed, 5 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.truffle.dsl.processor/src/com/oracle/truffle/dsl/processor/node/NodeMethodParser.java Thu Aug 29 14:28:32 2013 +0200 +++ b/graal/com.oracle.truffle.dsl.processor/src/com/oracle/truffle/dsl/processor/node/NodeMethodParser.java Thu Aug 29 14:28:43 2013 +0200 @@ -85,10 +85,14 @@ return methodSpec; } - private void addDefaultChildren(boolean shortCircuitsEnabled, String shortCircuitName, MethodSpec methodSpec) { + public void addDefaultChildren(boolean shortCircuitsEnabled, String breakName, MethodSpec methodSpec) { // children are null when parsing executable types if (getNode().getChildren() != null) { for (NodeChildData child : getNode().getChildren()) { + String valueName = child.getName(); + if (breakName != null && valueName.equals(breakName)) { + break; + } if (child.getExecutionKind() == ExecutionKind.DEFAULT) { ParameterSpec spec = createValueParameterSpec(child.getName(), child.getNodeData(), child.getExecuteWith().size()); if (child.getCardinality().isMany()) { @@ -97,10 +101,6 @@ } methodSpec.addRequired(spec); } else if (child.getExecutionKind() == ExecutionKind.SHORT_CIRCUIT) { - String valueName = child.getName(); - if (shortCircuitName != null && valueName.equals(shortCircuitName)) { - break; - } if (shortCircuitsEnabled) { methodSpec.addRequired(new ParameterSpec(shortCircuitValueName(valueName), getContext().getType(boolean.class)));