symTable en cours

This commit is contained in:
trochas
2025-04-09 16:08:54 +02:00
5 changed files with 55 additions and 22 deletions

View File

@@ -137,7 +137,9 @@ public class toLLVM_Visitor implements ProgramVisitor<SymTable,ProgramLLVMImpl>
if(val1.getType().getClass() != val1.getType().getClass()){
throw new UnsupportedOperationException("Type error in VSL file");
}
String temp = h.addNewTempVar();
Result r = h.addNewTempVar();
String temp = r.var;
h = r.symTable;
VarLLVMImpl var = new VarLLVMImpl(type,temp);
list.add(new AssignLVMImpl(var, new BinOpLLVMImpl(type,e.op(),val1,val2)));