diff options
Diffstat (limited to 'st/MethodInstance.java')
-rw-r--r-- | st/MethodInstance.java | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/st/MethodInstance.java b/st/MethodInstance.java index 25096d2..c7df92f 100644 --- a/st/MethodInstance.java +++ b/st/MethodInstance.java @@ -6,7 +6,6 @@ public class MethodInstance extends AbstractInstance { private ArrayList<TypeInstance> args; // the list of arguments private ArrayList<TypeInstance> lvars; // the list of local variables private TypeEnum rtrn; // the returned type - private ClassInstance scope; // the surrounding class public MethodInstance(String name, TypeEnum rtrn) { super(name, TypeEnum.method); @@ -15,12 +14,20 @@ public class MethodInstance extends AbstractInstance { this.rtrn = rtrn; } - public void addArgument(TypeInstance arg) { + public ArrayList<TypeInstance> getArguments() { + return this.args; + } + + public ArrayList<TypeInstance> getLocals() { + return this.lvars; + } + + protected void addArgument(TypeInstance arg) { this.args.add(arg); this.lvars.add(arg); } - public void addLocal(TypeInstance lvar) { + protected void addLocal(TypeInstance lvar) { this.lvars.add(lvar); } |