diff options
Diffstat (limited to 'submit/SymbolInfo.java')
-rw-r--r-- | submit/SymbolInfo.java | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/submit/SymbolInfo.java b/submit/SymbolInfo.java index 19c3f9b..c640718 100644 --- a/submit/SymbolInfo.java +++ b/submit/SymbolInfo.java @@ -16,6 +16,7 @@ public class SymbolInfo { // In the case of a function, type is the return type private final VarType type; private final boolean function; + private int offset; public SymbolInfo(String id, VarType type, boolean function) { this.id = id; @@ -23,9 +24,20 @@ public class SymbolInfo { this.function = function; } + public SymbolInfo(String id, VarType type, boolean function, int offset) { + this(id, type, function); + this.offset = offset; + } + @Override public String toString() { return "<" + id + ", " + type + '>'; } + public VarType getType() { return type; } + + public boolean isFunction() { return function; } + + public int getOffset() { return offset; } + public void setOffset(int offset) { this.offset = offset; } } |