summaryrefslogtreecommitdiff
path: root/st/TypeInstance.java
diff options
context:
space:
mode:
authorbd-912 <bdunahu@colostate.edu>2024-04-14 02:21:48 -0600
committerbd-912 <bdunahu@colostate.edu>2024-04-14 02:21:48 -0600
commitee60d3f9a32f75c628961f40a9bf4f1bf387ac06 (patch)
treef424f292d987f6472f9ca1f5283127797461a075 /st/TypeInstance.java
parent6ecd1893b4586c7077c6969431b47ca4e0962240 (diff)
Proper Allocation sizes for Boil VarDeclaration
Diffstat (limited to 'st/TypeInstance.java')
-rw-r--r--st/TypeInstance.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/st/TypeInstance.java b/st/TypeInstance.java
index 596f638..65311a8 100644
--- a/st/TypeInstance.java
+++ b/st/TypeInstance.java
@@ -12,6 +12,11 @@ public class TypeInstance extends AbstractInstance {
this.cls = cls;
}
+ public int getSize() {
+ return (this.cls != null) ?
+ cls.getSize() : 4;
+ }
+
public ClassInstance getClassInstance() {
return this.cls;
}