Fehler in Umwandlung von RefType zu GTV in BoGTV beheben

This commit is contained in:
JanUlrich 2015-03-03 18:24:14 +01:00
parent 618847bf4f
commit 1ec9c3f67f

View File

@ -88,14 +88,16 @@ public class BoundedGenericTypeVar extends GenericTypeVar
ConstraintsSet ret = super.TYPE(ass);
//ass.addGenericVarAssumption(this);
//Die Type methode der BoundedGenericTypeVar schreibt zusätzlich noch die Constraints für die bounds
Vector<Type> tempBounds = new Vector<>();
if(this.bounds != null){
for(Type ev : this.bounds){
ConstraintType extendsType = ass.getTypeFor(ev, this);
if(extendsType == null)throw new TypeinferenceException("Der Typ "+ev.getName()+" ist nicht korrekt", this);
tempBounds.add(extendsType.getType());
//ret.add(new SingleConstraint(ass.getTypeFor(this, this), extendsType ));
}
}
this.bounds = tempBounds;
return ret;
}