Mercurial > hg > graal-jvmci-8
comparison graal/com.oracle.truffle.codegen.processor/src/com/oracle/truffle/codegen/processor/node/SpecializationThrowsData.java @ 8243:d81ff782fa1a
Removed @SpecializationThrows from codegen API. Replaced it by a simplier version in @Specialization.
author | Christian Humer <christian.humer@gmail.com> |
---|---|
date | Mon, 04 Mar 2013 17:20:26 +0100 |
parents | 5e3d1a68664e |
children | 0905d796944a |
comparison
equal
deleted
inserted
replaced
8242:ac4e8c16ffdf | 8243:d81ff782fa1a |
---|---|
27 | 27 |
28 public class SpecializationThrowsData { | 28 public class SpecializationThrowsData { |
29 | 29 |
30 private final AnnotationMirror annotationMirror; | 30 private final AnnotationMirror annotationMirror; |
31 private final TypeMirror javaClass; | 31 private final TypeMirror javaClass; |
32 private final String transitionTo; | |
33 private SpecializationData specialization; | 32 private SpecializationData specialization; |
34 | 33 |
35 public SpecializationThrowsData(AnnotationMirror annotationMirror, TypeMirror javaClass, String transitionTo) { | 34 public SpecializationThrowsData(AnnotationMirror annotationMirror, TypeMirror javaClass) { |
36 this.annotationMirror = annotationMirror; | 35 this.annotationMirror = annotationMirror; |
37 this.javaClass = javaClass; | 36 this.javaClass = javaClass; |
38 this.transitionTo = transitionTo; | |
39 } | 37 } |
40 | 38 |
41 void setSpecialization(SpecializationData specialization) { | 39 void setSpecialization(SpecializationData specialization) { |
42 this.specialization = specialization; | 40 this.specialization = specialization; |
43 } | 41 } |
52 | 50 |
53 public AnnotationMirror getAnnotationMirror() { | 51 public AnnotationMirror getAnnotationMirror() { |
54 return annotationMirror; | 52 return annotationMirror; |
55 } | 53 } |
56 | 54 |
57 public String getTransitionToName() { | |
58 return transitionTo; | |
59 } | |
60 | |
61 public SpecializationData getTransitionTo() { | 55 public SpecializationData getTransitionTo() { |
62 for (SpecializationData s : specialization.getNode().getSpecializations()) { | 56 return specialization.findNextSpecialization(); |
63 if (s.getMethodName().equals(transitionTo)) { | |
64 return s; | |
65 } | |
66 } | |
67 return null; | |
68 } | 57 } |
69 } | 58 } |