diff --git a/src/de/dhbwstuttgart/typeinference/typeAlgo/TYPE.java b/src/de/dhbwstuttgart/typeinference/typeAlgo/TYPE.java index a799d8e2..ccb70002 100644 --- a/src/de/dhbwstuttgart/typeinference/typeAlgo/TYPE.java +++ b/src/de/dhbwstuttgart/typeinference/typeAlgo/TYPE.java @@ -221,7 +221,7 @@ public class TYPE implements StatementVisitor{ protected Constraint generateConstraint(MethodCall forMethod, MethodAssumption assumption, TypeInferenceBlockInformation info){ Constraint methodConstraint = new Constraint(); methodConstraint.add(ConstraintsFactory.createPair(forMethod.receiver.getType(), assumption.getReceiverType(), PairOperator.SMALLERDOT, info)); - methodConstraint.add(ConstraintsFactory.createPair(assumption.getReturnType(), forMethod.getType(), PairOperator.SMALLERDOT, info)); + methodConstraint.add(ConstraintsFactory.createPair(assumption.getReturnType(), forMethod.getType(), PairOperator.EQUALSDOT, info)); methodConstraint.addAll(generateParameterConstraints(forMethod, assumption, info)); return methodConstraint; } @@ -229,8 +229,8 @@ public class TYPE implements StatementVisitor{ protected Set generateParameterConstraints(MethodCall foMethod, MethodAssumption assumption, TypeInferenceBlockInformation info) { Set ret = new HashSet<>(); for(int i = 0;i { -mathStruc(A a) { ;} +mathStruc(A a) { } A model(){ A a; return a; } diff --git a/test/typeinference/JavaTXCompilerTest.java b/test/typeinference/JavaTXCompilerTest.java index 1a02861c..696a56d4 100644 --- a/test/typeinference/JavaTXCompilerTest.java +++ b/test/typeinference/JavaTXCompilerTest.java @@ -30,8 +30,8 @@ public class JavaTXCompilerTest extends JavaTXCompiler { @Test public void test() throws IOException, ClassNotFoundException { - //filesToTest.add(new File(rootDirectory+"Faculty.jav")); - filesToTest.add(new File(rootDirectory+"mathStruc.jav")); + filesToTest.add(new File(rootDirectory+"Faculty.jav")); + //filesToTest.add(new File(rootDirectory+"mathStruc.jav")); //filesToTest.add(new File(rootDirectory+"Lambda.jav")); //filesToTest.add(new File(rootDirectory+"Lambda2.jav")); //filesToTest.add(new File(rootDirectory+"Lambda3.jav"));