Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.dsl.processor/src/com/oracle/truffle/dsl/processor/template/TemplateMethod.java @ 10602:b8fe1fe004ec
Truffle-DSL: fixed bugs in the generated polymorphic code generation.
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Tue, 02 Jul 2013 19:21:59 +0200 |
parents | e93efe3ba5f4 |
children | 6879565ee10b |
comparison
equal
deleted
inserted
replaced
10601:5acc3f3016b7 | 10602:b8fe1fe004ec |
---|---|
26 | 26 |
27 import javax.lang.model.element.*; | 27 import javax.lang.model.element.*; |
28 import javax.lang.model.type.*; | 28 import javax.lang.model.type.*; |
29 | 29 |
30 import com.oracle.truffle.dsl.processor.*; | 30 import com.oracle.truffle.dsl.processor.*; |
31 import com.oracle.truffle.dsl.processor.template.TemplateMethod.Signature; | |
32 import com.oracle.truffle.dsl.processor.typesystem.*; | 31 import com.oracle.truffle.dsl.processor.typesystem.*; |
33 | 32 |
34 /** | 33 /** |
35 * Note: this class has a natural ordering that is inconsistent with equals. | 34 * Note: this class has a natural ordering that is inconsistent with equals. |
36 */ | 35 */ |
139 } | 138 } |
140 | 139 |
141 public List<ActualParameter> findParameters(ParameterSpec spec) { | 140 public List<ActualParameter> findParameters(ParameterSpec spec) { |
142 List<ActualParameter> foundParameters = new ArrayList<>(); | 141 List<ActualParameter> foundParameters = new ArrayList<>(); |
143 for (ActualParameter param : getReturnTypeAndParameters()) { | 142 for (ActualParameter param : getReturnTypeAndParameters()) { |
144 if (param.getSpecification().equals(spec)) { | 143 if (param.getSpecification().getName().equals(spec.getName())) { |
145 foundParameters.add(param); | 144 foundParameters.add(param); |
146 } | 145 } |
147 } | 146 } |
148 return foundParameters; | 147 return foundParameters; |
149 } | 148 } |