forked from JavaTX/JavaCompilerCore
Fehler beheben
This commit is contained in:
parent
c58d706c01
commit
615d2c633e
@ -3,6 +3,7 @@ package de.dhbwstuttgart.typeinference;
|
|||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
|
|
||||||
import de.dhbwstuttgart.syntaxtree.FormalParameter;
|
import de.dhbwstuttgart.syntaxtree.FormalParameter;
|
||||||
|
import de.dhbwstuttgart.syntaxtree.Class;
|
||||||
import de.dhbwstuttgart.syntaxtree.Method;
|
import de.dhbwstuttgart.syntaxtree.Method;
|
||||||
import de.dhbwstuttgart.syntaxtree.ParameterList;
|
import de.dhbwstuttgart.syntaxtree.ParameterList;
|
||||||
import de.dhbwstuttgart.syntaxtree.misc.DeclId;
|
import de.dhbwstuttgart.syntaxtree.misc.DeclId;
|
||||||
@ -32,6 +33,7 @@ public class FunNMethod extends Method{
|
|||||||
}
|
}
|
||||||
pl.formalparameter = fpList;
|
pl.formalparameter = fpList;
|
||||||
this.parameterlist = pl;
|
this.parameterlist = pl;
|
||||||
|
this.parent = new Class("Fun"+paralist.size(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public FunNMethod(int N){
|
public FunNMethod(int N){
|
||||||
@ -49,6 +51,7 @@ public class FunNMethod extends Method{
|
|||||||
}
|
}
|
||||||
pl.formalparameter = fpList;
|
pl.formalparameter = fpList;
|
||||||
this.parameterlist = pl;
|
this.parameterlist = pl;
|
||||||
|
this.parent = new Class("Fun"+N, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -77,14 +77,14 @@ public class TypeInsertSet {
|
|||||||
GenericVarPatch gPatch = new GenericVarPatch();//Set der Einzusetzenden generischen Variablendeklarationen
|
GenericVarPatch gPatch = new GenericVarPatch();//Set der Einzusetzenden generischen Variablendeklarationen
|
||||||
//Schritt 1:
|
//Schritt 1:
|
||||||
Vector<TypePlaceholder> involvedTPHs = tip.getInsertType().getInvolvedTypePlaceholder();//.getInvolvedTypePlaceholder();
|
Vector<TypePlaceholder> involvedTPHs = tip.getInsertType().getInvolvedTypePlaceholder();//.getInvolvedTypePlaceholder();
|
||||||
/*
|
|
||||||
//Schritt 2:
|
//Schritt 2:
|
||||||
Vector<Pair> pairs = new Vector<>();
|
Vector<Pair> pairs = new Vector<>();
|
||||||
for(Pair pair : this.resultSet.getConstraintsFor(involvedTPHs)){
|
for(Pair pair : this.resultSet.getConstraintsFor(involvedTPHs)){
|
||||||
//gPatch.add(pair); //Schritt 6 (Teil 2)
|
//gPatch.add(pair); //Schritt 6 (Teil 2)
|
||||||
pairs.add(pair);
|
pairs.add(pair);
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
//Schritt 3:
|
//Schritt 3:
|
||||||
Vector<TypePlaceholder> allTPHs = new Vector<>();
|
Vector<TypePlaceholder> allTPHs = new Vector<>();
|
||||||
for(TypePlaceholder tph : involvedTPHs){
|
for(TypePlaceholder tph : involvedTPHs){
|
||||||
@ -102,7 +102,7 @@ public class TypeInsertSet {
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
//gPatch.addPairs(pairs);
|
gPatch.addPairs(pairs);
|
||||||
gPatch.addTPHs(allTPHs);
|
gPatch.addTPHs(allTPHs);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user