aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/vhdl/translate/trans-chap3.ads3
-rw-r--r--src/vhdl/translate/trans-chap8.adb5
2 files changed, 8 insertions, 0 deletions
diff --git a/src/vhdl/translate/trans-chap3.ads b/src/vhdl/translate/trans-chap3.ads
index 2b9f37e6b..783e1ae90 100644
--- a/src/vhdl/translate/trans-chap3.ads
+++ b/src/vhdl/translate/trans-chap3.ads
@@ -126,6 +126,9 @@ package Trans.Chap3 is
-- number of dimensions; these fields are a structure describing the
-- range of the dimension.
+ procedure Gen_Call_Type_Builder
+ (Layout : Mnode; Var_Type : Iir; Kind : Object_Kind_Type);
+
-- If the element subtype of ARR_TYPE is unbounded, create a fat pointer,
-- set the bounds of it (from ARR), and return it.
-- Otherwise, return a null mnode.
diff --git a/src/vhdl/translate/trans-chap8.adb b/src/vhdl/translate/trans-chap8.adb
index 318d0142f..4d608c839 100644
--- a/src/vhdl/translate/trans-chap8.adb
+++ b/src/vhdl/translate/trans-chap8.adb
@@ -2893,6 +2893,11 @@ package body Trans.Chap8 is
or else (Get_Interface_Of_Formal (Get_Formal (Next_Assoc))
/= Base_Formal)
then
+ -- * compute the size of the object
+ Chap3.Gen_Call_Type_Builder
+ (Chap3.Get_Composite_Bounds (Params (Last_Individual)),
+ Get_Type (Base_Formal), Formal_Object_Kind);
+
-- * allocate base
Chap3.Allocate_Unbounded_Composite_Base
(Alloc, Saved_Val (Last_Individual),