Changed inheritance to separate task/method descriptors again
[IRC.git] / Robust / src / IR / State.java
index b25453929608cfc85b7da0865a0e3e99396783b7..c893c20ee70e0ceb9c1579297fe01a869074a4f0 100644 (file)
@@ -76,6 +76,10 @@ public class State {
        return (BlockNode)treemethodmap.get(md);
     }
 
+    public BlockNode getMethodBody(TaskDescriptor td) {
+       return (BlockNode)treemethodmap.get(td);
+    }
+
     public SymbolTable getClassSymbolTable() {
        return classes;
     }
@@ -100,6 +104,10 @@ public class State {
        flatmethodmap.put(md,bn);
     }
 
+    public void addFlatCode(TaskDescriptor td, FlatMethod bn) {
+       flatmethodmap.put(td,bn);
+    }
+
     public void addTask(TaskDescriptor td) {
        if (tasks.contains(td.getSymbol()))
            throw new Error("Task "+td.getSymbol()+" defined twice");