diff --git a/src/de/dhbwstuttgart/core/JavaTXCompiler.java b/src/de/dhbwstuttgart/core/JavaTXCompiler.java index 43f56d51..31271ffd 100644 --- a/src/de/dhbwstuttgart/core/JavaTXCompiler.java +++ b/src/de/dhbwstuttgart/core/JavaTXCompiler.java @@ -1,5 +1,6 @@ package de.dhbwstuttgart.core; +import de.dhbwstuttgart.parser.ClassNotFoundException; import de.dhbwstuttgart.parser.JavaTXParser; import de.dhbwstuttgart.syntaxtree.ClassOrInterface; import de.dhbwstuttgart.syntaxtree.SourceFile; diff --git a/src/de/dhbwstuttgart/parser/JavaTXParser.java b/src/de/dhbwstuttgart/parser/JavaTXParser.java index 2acd90ae..38f92d6b 100644 --- a/src/de/dhbwstuttgart/parser/JavaTXParser.java +++ b/src/de/dhbwstuttgart/parser/JavaTXParser.java @@ -33,6 +33,7 @@ public class JavaTXParser { } //TODO: Wieso muss man das händisch anhängen? ret.add("java.lang.Object"); + return ret; } } diff --git a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/StatementGenerator.java b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/StatementGenerator.java index c75f6166..9ad4f227 100644 --- a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/StatementGenerator.java +++ b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/StatementGenerator.java @@ -33,40 +33,7 @@ public class StatementGenerator { this.generics = generics; } - public Method convert(Java8Parser.MethodDeclarationContext methodDeclarationContext, JavaClassName parentClass) { - Java8Parser.MethodHeaderContext header = methodDeclarationContext.methodHeader(); - String name = header.methodDeclarator().Identifier().getText(); - GenericDeclarationList gtvDeclarations = new GenericDeclarationList(new ArrayList<>(), methodDeclarationContext.methodHeader().getStart()); - if(methodDeclarationContext.methodHeader().typeParameters() != null){ - gtvDeclarations = TypeGenerator.convert(methodDeclarationContext.methodHeader().typeParameters(), parentClass, name,reg, generics); - } - RefTypeOrTPHOrWildcardOrGeneric retType; - if(header.result() != null){ - if(header.result().unannType() != null){ - retType = TypeGenerator.convert(header.result().unannType(), reg, generics); - } - else retType = new de.dhbwstuttgart.syntaxtree.type.Void(header.result().getStart()); - }else{ - retType = TypePlaceholder.fresh(header.getStart()); - } - int modifiers = SyntaxTreeGenerator.convert(methodDeclarationContext.methodModifier()); - ParameterList parameterList = convert(header.methodDeclarator().formalParameterList()); - Block block = null; - if(methodDeclarationContext.methodBody().block() == null){ - if(! Modifier.isAbstract(modifiers)){ - //TODO: Error! Abstrakte Methode ohne abstrakt Keyword - } - }else{ - block = this.convert(methodDeclarationContext.methodBody().block()); - } - if(parentClass.equals(new JavaClassName(name))){ - return new Constructor(name, retType, modifiers, parameterList, block, gtvDeclarations, methodDeclarationContext.getStart()); - }else{ - return new Method(name, retType, modifiers, parameterList,block, gtvDeclarations, methodDeclarationContext.getStart()); - } - } - - private ParameterList convert(Java8Parser.FormalParameterListContext formalParameterListContext) { + public ParameterList convert(Java8Parser.FormalParameterListContext formalParameterListContext) { List ret = new ArrayList<>(); List fps = new ArrayList<>(); if(formalParameterListContext == null || formalParameterListContext.lastFormalParameter() == null) @@ -832,9 +799,9 @@ public class StatementGenerator { funNParams.add(TypePlaceholder.fresh(expression.getStart()));//ret-Type params.getFormalparalist().forEach(formalParameter -> //Für jeden Parameter einen TPH anfügen: funNParams.add(TypePlaceholder.fresh(expression.getStart()))); - RefType lambdaType = new RefType(reg.getName("Fun"+params.getFormalparalist().size()), - funNParams, expression.getStart()); + RefTypeOrTPHOrWildcardOrGeneric lambdaType = TypePlaceholder.fresh(expression.getStart()); + //RefType lambdaType = new RefType(reg.getName("Fun"+params.getFormalparalist().size()), + //funNParams, expression.getStart()); return new LambdaExpression(lambdaType, params, block, expression.getStart()); } - } diff --git a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java index 84d2cee2..8d4a6934 100644 --- a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java +++ b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/SyntaxTreeGenerator.java @@ -17,6 +17,7 @@ import java.util.ArrayList; import java.util.HashMap; import java.util.List; +import jdk.internal.dynalink.support.TypeConverterFactory; import org.antlr.v4.runtime.Token; import org.antlr.v4.runtime.tree.TerminalNode; @@ -24,7 +25,6 @@ public class SyntaxTreeGenerator{ private JavaClassRegistry reg; private String pkgName = ""; List imports = new ArrayList(); - private GenericsRegistry generics = new GenericsRegistry(); public SyntaxTreeGenerator(JavaClassRegistry reg){ this.reg = reg; @@ -52,11 +52,13 @@ public class SyntaxTreeGenerator{ nameString = typeDecl.interfaceDeclaration().normalInterfaceDeclaration().Identifier().toString(); } //Die Generic TypeParameter Definitionen Nicht! an die JavaClassName-Registry anfügen: + /* //Diese gelängen dadurch in den globalen Scope, was sie schließlich nicht sind if(typeDecl.classDeclaration().normalClassDeclaration().typeParameters() != null){ for(Java8Parser.TypeParameterContext tp : typeDecl.classDeclaration().normalClassDeclaration().typeParameters().typeParameterList().typeParameter()){ //this.reg.add(tp.Identifier().toString()); } } + */ this.reg.add(nameString); } } @@ -68,12 +70,14 @@ public class SyntaxTreeGenerator{ else{ nameString = typeDecl.classDeclaration().normalClassDeclaration().Identifier().toString(); } - //Die Generic TypeParameter Definitionen ebenfalls an die JavaClassName-Registry anfügen: + //Die Generic TypeParameter Definitionen Nicht! an die JavaClassName-Registry anfügen: + /* //Diese gelängen dadurch in den globalen Scope, was sie schließlich nicht sind if(typeDecl.classDeclaration().normalClassDeclaration().typeParameters() != null){ for(Java8Parser.TypeParameterContext tp : typeDecl.classDeclaration().normalClassDeclaration().typeParameters().typeParameterList().typeParameter()){ this.reg.add(tp.Identifier().toString()); } } + */ this.reg.add(nameString); } } @@ -180,6 +184,60 @@ public class SyntaxTreeGenerator{ return new SourceFile(this.pkgName, classes, this.imports); } + public Method convert(Java8Parser.MethodDeclarationContext methodDeclarationContext, JavaClassName parentClass, GenericsRegistry generics) { + Java8Parser.MethodHeaderContext header = methodDeclarationContext.methodHeader(); + int modifiers = SyntaxTreeGenerator.convert(methodDeclarationContext.methodModifier()); + GenericsRegistry localGenerics = createGenerics(methodDeclarationContext.methodHeader().typeParameters(), + parentClass, header.methodDeclarator().Identifier().getText()); + localGenerics.putAll(generics); + return convert(modifiers, header, methodDeclarationContext.methodBody(),parentClass, localGenerics); + } + + public Method convert(Java8Parser.InterfaceMethodDeclarationContext ctx, JavaClassName parentClass, GenericsRegistry generics) { + Java8Parser.MethodHeaderContext header = ctx.methodHeader(); + int modifiers = SyntaxTreeGenerator.convertInterfaceModifier(ctx.interfaceMethodModifier()); + + GenericsRegistry localGenerics = createGenerics(header.typeParameters(), parentClass, header.methodDeclarator().Identifier().getText()); + localGenerics.putAll(generics); + + return convert(modifiers, header, ctx.methodBody(),parentClass, localGenerics); + } + + private Method convert(int modifiers, Java8Parser.MethodHeaderContext header, Java8Parser.MethodBodyContext body, + JavaClassName parentClass, GenericsRegistry localGenerics) { + + StatementGenerator stmtGen = new StatementGenerator(reg, localGenerics); + + String name = header.methodDeclarator().Identifier().getText(); + GenericDeclarationList gtvDeclarations = new GenericDeclarationList(new ArrayList<>(), header.getStart()); + if(header.typeParameters() != null){ + gtvDeclarations = TypeGenerator.convert(header.typeParameters(), parentClass, name,reg, localGenerics); + } + RefTypeOrTPHOrWildcardOrGeneric retType; + if(header.result() != null){ + if(header.result().unannType() != null){ + retType = TypeGenerator.convert(header.result().unannType(), reg, localGenerics); + } + else retType = new de.dhbwstuttgart.syntaxtree.type.Void(header.result().getStart()); + }else{ + retType = TypePlaceholder.fresh(header.getStart()); + } + ParameterList parameterList = stmtGen.convert(header.methodDeclarator().formalParameterList()); + Block block = null; + if(body.block() == null){ + if(! Modifier.isAbstract(modifiers)){ + //TODO: Error! Abstrakte Methode ohne abstrakt Keyword + } + }else{ + block = stmtGen.convert(body.block()); + } + if(parentClass.equals(new JavaClassName(name))){ + return new Constructor(name, retType, modifiers, parameterList, block, gtvDeclarations, header.getStart()); + }else{ + return new Method(name, retType, modifiers, parameterList,block, gtvDeclarations, header.getStart()); + } + } + private ClassOrInterface convertClass(Java8Parser.ClassDeclarationContext ctx) { ClassOrInterface newClass; if(ctx.normalClassDeclaration() != null){ @@ -200,10 +258,11 @@ public class SyntaxTreeGenerator{ } } JavaClassName name = reg.getName(ctx.Identifier().getText()); + GenericsRegistry generics = createGenerics(ctx.typeParameters(), name, ""); Token offset = ctx.getStart(); GenericDeclarationList genericClassParameters = TypeGenerator.convert(ctx.typeParameters(), name, "",reg, generics); - List fielddecl = convertFields(ctx.classBody()); - List methods = convertMethods(ctx.classBody(), name); + List fielddecl = convertFields(ctx.classBody(), generics); + List methods = convertMethods(ctx.classBody(), name, generics); List konstruktoren = new ArrayList<>(); for(int i = 0; i implementedInterfaces = null; - return new ClassOrInterface(modifiers, name, fielddecl, methods, konstruktoren, genericClassParameters, superClass, isInterface, implementedInterfaces, offset); + List implementedInterfaces = convert(ctx.superinterfaces(), generics); + return new ClassOrInterface(modifiers, name, fielddecl, methods, konstruktoren, genericClassParameters, superClass, + isInterface, implementedInterfaces, offset); + } + + private List convert(Java8Parser.SuperinterfacesContext ctx, GenericsRegistry generics) { + if(ctx == null)return new ArrayList<>(); + return convert(ctx.interfaceTypeList(), generics); + } + + private List convert(Java8Parser.InterfaceTypeListContext ctx, GenericsRegistry generics) { + List ret = new ArrayList<>(); + for(Java8Parser.InterfaceTypeContext interfaceType : ctx.interfaceType()){ + ret.add(TypeGenerator.convert(interfaceType.classType(), reg, generics)); + } + return ret; } private Constructor generateStandardConstructor(String className, GenericDeclarationList classGenerics, Token offset){ @@ -244,7 +317,8 @@ public class SyntaxTreeGenerator{ throw new NotImplementedException(); } - private List convertMethods(Java8Parser.ClassBodyContext classBodyContext, JavaClassName parentClass) { + private List convertMethods(Java8Parser.ClassBodyContext classBodyContext, + JavaClassName parentClass, GenericsRegistry generics) { List ret = new ArrayList<>(); for(Java8Parser.ClassBodyDeclarationContext classMember : classBodyContext.classBodyDeclaration()){ if(classMember.classMemberDeclaration() != null){ @@ -252,21 +326,21 @@ public class SyntaxTreeGenerator{ if(classMemberDeclarationContext.fieldDeclaration() != null){ //Do nothing! }else if(classMemberDeclarationContext.methodDeclaration()!= null){ - StatementGenerator stmtGen = new StatementGenerator(reg, generics); - ret.add(stmtGen.convert(classMemberDeclarationContext.methodDeclaration(), parentClass)); + + ret.add(this.convert(classMemberDeclarationContext.methodDeclaration(), parentClass, generics)); } } } return ret; } - private List convertFields(Java8Parser.ClassBodyContext classBodyContext) { + private List convertFields(Java8Parser.ClassBodyContext classBodyContext, GenericsRegistry generics) { List ret = new ArrayList<>(); for(Java8Parser.ClassBodyDeclarationContext classMember : classBodyContext.classBodyDeclaration()){ if(classMember.classMemberDeclaration() != null){ Java8Parser.ClassMemberDeclarationContext classMemberDeclarationContext = classMember.classMemberDeclaration(); if(classMemberDeclarationContext.fieldDeclaration() != null){ - ret.addAll(convert(classMember.classMemberDeclaration().fieldDeclaration())); + ret.addAll(convert(classMember.classMemberDeclaration().fieldDeclaration(), generics)); }else if(classMemberDeclarationContext.methodDeclaration()!= null){ //Do nothing! } @@ -283,7 +357,15 @@ public class SyntaxTreeGenerator{ return ret; } - private List convert(Java8Parser.FieldDeclarationContext fieldDeclarationContext) { + public static int convertInterfaceModifier(List methodModifierContexts) { + int ret = 0; + for(Java8Parser.InterfaceMethodModifierContext mod : methodModifierContexts){ + if(mod.annotation() == null)convertModifier(mod.getText()); + } + return ret; + } + + private List convert(Java8Parser.FieldDeclarationContext fieldDeclarationContext, GenericsRegistry generics) { List ret = new ArrayList<>(); int modifiers = 0; for(Java8Parser.FieldModifierContext fieldModifierContext : fieldDeclarationContext.fieldModifier()){ @@ -333,7 +415,7 @@ public class SyntaxTreeGenerator{ modifiers.put(Modifier.toString(Modifier.INTERFACE), Modifier.INTERFACE); int ret = 0; for(String m : modifiers.keySet()){ - if(modifier.startsWith(m))ret+=modifiers.get(m); + if(modifier.contains(m))ret+=modifiers.get(m); } return ret; } @@ -347,13 +429,86 @@ public class SyntaxTreeGenerator{ if(ctx.annotation() != null)return 0; return convertModifier(ctx.getText()); } + + private int convert(Java8Parser.InterfaceModifierContext ctx) { + if(ctx.annotation() != null)return 0; + return convertModifier(ctx.getText()); + } private ClassOrInterface convertEnum(Java8Parser.EnumDeclarationContext ctx){ return null; } private ClassOrInterface convertInterface(Java8Parser.InterfaceDeclarationContext ctx){ - return null; + if(ctx.normalInterfaceDeclaration() != null){ + return convertNormal(ctx.normalInterfaceDeclaration()); + }else{ + throw new NotImplementedException(); + } } + private ClassOrInterface convertNormal(Java8Parser.NormalInterfaceDeclarationContext ctx) { + int modifiers = 0; + if(ctx.interfaceModifier() != null){ + for( Java8Parser.InterfaceModifierContext mod : ctx.interfaceModifier()){ + int newModifier = convert(mod); + modifiers += newModifier; + } + } + JavaClassName name = reg.getName(ctx.Identifier().getText()); + + GenericsRegistry generics = createGenerics(ctx.typeParameters(), name, ""); + + List fields = convertFields(ctx.interfaceBody()); + List methods = convertMethods(ctx.interfaceBody(), name, generics); + + GenericDeclarationList genericParams = TypeGenerator.convert(ctx.typeParameters(), name, "",reg, generics); + RefType superClass = new ASTFactory(reg).createObjectClass().getType(); + + List extendedInterfaces = convert(ctx.extendsInterfaces(), generics); + + return new ClassOrInterface(modifiers, name, fields, methods, new ArrayList<>(), + genericParams, superClass, true, extendedInterfaces, ctx.getStart()); + } + + private GenericsRegistry createGenerics(Java8Parser.TypeParametersContext ctx, JavaClassName parentClass, String parentMethod) { + GenericsRegistry ret = new GenericsRegistry(); + if(ctx == null || ctx.typeParameterList() == null)return ret; + for(Java8Parser.TypeParameterContext tp : ctx.typeParameterList().typeParameter()){ + TypeGenerator.convert(tp, parentClass, parentMethod, reg, ret); + } + return ret; + } + + private List convert(Java8Parser.ExtendsInterfacesContext extendsInterfacesContext, GenericsRegistry generics) { + if(extendsInterfacesContext == null)return new ArrayList<>(); + return convert(extendsInterfacesContext.interfaceTypeList(), generics); + } + + private List convertMethods(Java8Parser.InterfaceBodyContext interfaceBodyContext, + JavaClassName parentClass, GenericsRegistry generics) { + List ret = new ArrayList<>(); + for(Java8Parser.InterfaceMemberDeclarationContext member : interfaceBodyContext.interfaceMemberDeclaration()){ + if(member.interfaceMethodDeclaration() != null){ + ret.add(this.convert(member.interfaceMethodDeclaration(), parentClass, generics)); + //new Method(name, type, modifier, params, null, genericDecls, member.interfaceMethodDeclaration().getStart()); + }else{ + throw new NotImplementedException(); + } + } + return ret; + } + + private List convertFields(Java8Parser.InterfaceBodyContext interfaceBodyContext) { + List ret = new ArrayList<>(); + for(Java8Parser.InterfaceMemberDeclarationContext member : interfaceBodyContext.interfaceMemberDeclaration()){ + if(member.constantDeclaration() != null){ + //TODO: Erstelle hier ein Feld! + throw new NotImplementedException(); + } + } + return ret; + } + + } diff --git a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/TypeGenerator.java b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/TypeGenerator.java index 0d30132e..0d4d9fba 100644 --- a/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/TypeGenerator.java +++ b/src/de/dhbwstuttgart/parser/SyntaxTreeGenerator/TypeGenerator.java @@ -125,4 +125,9 @@ public class TypeGenerator { } return ret; } + + public static RefTypeOrTPHOrWildcardOrGeneric convert(Java8Parser.ClassTypeContext ctx, JavaClassRegistry reg, GenericsRegistry generics) { + if(ctx.classOrInterfaceType() != null)throw new NotImplementedException(); + return convertTypeName(ctx.Identifier().getText(), ctx.typeArguments(), ctx.getStart(), reg, generics); + } } diff --git a/src/de/dhbwstuttgart/syntaxtree/factory/UnifyTypeFactory.java b/src/de/dhbwstuttgart/syntaxtree/factory/UnifyTypeFactory.java index a76d347f..9d26ab90 100644 --- a/src/de/dhbwstuttgart/syntaxtree/factory/UnifyTypeFactory.java +++ b/src/de/dhbwstuttgart/syntaxtree/factory/UnifyTypeFactory.java @@ -99,7 +99,8 @@ public class UnifyTypeFactory { } public static UnifyType convert(GenericRefType t){ - return new PlaceholderType(TypePlaceholder.fresh(t.getOffset()).getName()); + throw new NotImplementedException(); + //return new PlaceholderType(TypePlaceholder.fresh(t.getOffset()).getName()); } public static UnifyType convert(WildcardType t){ diff --git a/src/de/dhbwstuttgart/syntaxtree/statement/LambdaExpression.java b/src/de/dhbwstuttgart/syntaxtree/statement/LambdaExpression.java index 2d9cf941..cf263ed0 100755 --- a/src/de/dhbwstuttgart/syntaxtree/statement/LambdaExpression.java +++ b/src/de/dhbwstuttgart/syntaxtree/statement/LambdaExpression.java @@ -48,7 +48,8 @@ public class LambdaExpression extends Expression implements TypeScope { @Override public RefTypeOrTPHOrWildcardOrGeneric getReturnType() { - RefType type = (RefType) this.getType(); - return type.getParaList().get(0); + //RefType type = (RefType) this.getType(); + //return type.getParaList().get(0); + return methodBody.getType(); } } diff --git a/test/javFiles/Lambda.jav b/test/javFiles/Lambda.jav index 8d394b0c..386ae7f7 100644 --- a/test/javFiles/Lambda.jav +++ b/test/javFiles/Lambda.jav @@ -4,9 +4,17 @@ String var; methode(){ return () -> (f) -> { - f.apply(this,var); + f.apply(this, var); return var; }; } +} + +interface Fun1{ + A apply(B b); +} + +interface Fun2{ + A apply(B b, C c); } \ No newline at end of file diff --git a/test/parser/FeatherWeightJavaTest.java b/test/parser/FeatherWeightJavaTest.java index 84113e0c..12db947f 100644 --- a/test/parser/FeatherWeightJavaTest.java +++ b/test/parser/FeatherWeightJavaTest.java @@ -1,5 +1,6 @@ package parser; +import de.dhbwstuttgart.parser.ClassNotFoundException; import de.dhbwstuttgart.parser.JavaTXParser; import de.dhbwstuttgart.syntaxtree.ClassOrInterface; import de.dhbwstuttgart.syntaxtree.Field; diff --git a/test/parser/FieldTest.java b/test/parser/FieldTest.java index 067ff23e..464e2007 100644 --- a/test/parser/FieldTest.java +++ b/test/parser/FieldTest.java @@ -1,5 +1,6 @@ package parser; +import de.dhbwstuttgart.parser.ClassNotFoundException; import de.dhbwstuttgart.parser.JavaTXParser; import de.dhbwstuttgart.syntaxtree.ClassOrInterface; import de.dhbwstuttgart.syntaxtree.Field; @@ -14,7 +15,7 @@ public class FieldTest { private static final String rootDirectory = System.getProperty("user.dir")+"/test/parser/"; @Test - public void test() throws IOException, ClassNotFoundException { + public void test() throws IOException, ClassNotFoundException, ClassNotFoundException { JavaTXParser parser = new JavaTXParser(); SourceFile f = parser.parse(new File(rootDirectory + "FieldVarTest.jav")); diff --git a/test/parser/GeneralParserTest.java b/test/parser/GeneralParserTest.java index fc293d13..53cb6f7b 100644 --- a/test/parser/GeneralParserTest.java +++ b/test/parser/GeneralParserTest.java @@ -30,10 +30,7 @@ public class GeneralParserTest{ filenames.add("ImportTest.jav"); filenames.add("CastTest.jav"); filenames.add("StatementsTest.jav"); -<<<<<<< HEAD //filenames.add("Methods.jav"); -======= ->>>>>>> f05222fb563282945ba395047f54f6b3059b10c5 filenames.add("ImportTestGeneric.jav"); filenames.add("CastTest.jav"); //filenames.add("BoundedParameter.jav"); diff --git a/test/parser/RunParserTest.java b/test/parser/RunParserTest.java index 5effe244..3028ef3d 100644 --- a/test/parser/RunParserTest.java +++ b/test/parser/RunParserTest.java @@ -1,7 +1,6 @@ package parser; import de.dhbwstuttgart.parser.JavaTXParser; -import de.dhbwstuttgart.parser.RunParser; import org.junit.Test; import java.io.File; diff --git a/test/typeinference/JavaTXCompilerTest.java b/test/typeinference/JavaTXCompilerTest.java index 7a73974b..4df1c29d 100644 --- a/test/typeinference/JavaTXCompilerTest.java +++ b/test/typeinference/JavaTXCompilerTest.java @@ -1,6 +1,7 @@ package typeinference; import de.dhbwstuttgart.core.JavaTXCompiler; +import de.dhbwstuttgart.parser.ClassNotFoundException; import org.junit.Test; import java.io.File; @@ -18,8 +19,8 @@ public class JavaTXCompilerTest { JavaTXCompiler compiler = new JavaTXCompiler(); //compiler.parse(new File(rootDirectory+"Methods.jav")); //compiler.parse(new File(rootDirectory+"Generics.jav")); - compiler.parse(new File(rootDirectory+"MethodsEasy.jav")); - //compiler.parse(new File(rootDirectory+"Lambda.jav")); + //compiler.parse(new File(rootDirectory+"MethodsEasy.jav")); + compiler.parse(new File(rootDirectory+"Lambda.jav")); compiler.typeInference(); } } \ No newline at end of file