NichtHaskell/Source/abstractSyntaxTree/Class/MethodDecl.java
2024-05-09 14:20:55 +02:00

34 lines
919 B
Java

package abstractSyntaxTree.Class;
import TypeCheck.TypeCheckResult;
import abstractSyntaxTree.Program;
import org.objectweb.asm.ClassWriter;
import java.util.HashMap;
import java.util.List;
public class MethodDecl implements IClass {
public String classThatContainsMethod;
public String name;
public List<String> parameters;
public String returnType;
//TODO: Move this into the typeCheck
private HashMap<String, String> localVars; // (type, identifier) // add content here
public TypeCheckResult typeCheck(HashMap<String, HashMap<String, HashMap<String, List<String>>>> methodContext, HashMap<String, HashMap<String, String>> typeContext, List<MethodDecl> fieldsOrMethods) throws Exception {
// write localvars
// jede methode als block statement aufrufen
return null;
}
@Override
public void codeGen(ClassWriter cw) throws Exception {
}
}