diff options
Diffstat (limited to 'src/grt')
-rw-r--r-- | src/grt/grt-rtis.adb | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/grt/grt-rtis.adb b/src/grt/grt-rtis.adb index 26d976459..7f4a00ff7 100644 --- a/src/grt/grt-rtis.adb +++ b/src/grt/grt-rtis.adb @@ -24,8 +24,11 @@ -- covered by the GNU Public License. package body Grt.Rtis is + Max_Top_Pkg : Ghdl_Index_Type := 0; + procedure Ghdl_Rti_Add_Package (Pkg : Ghdl_Rti_Access) is begin + pragma Assert (Ghdl_Rti_Top.Nbr_Child < Max_Top_Pkg); Ghdl_Rti_Top.Children (Ghdl_Rti_Top.Nbr_Child) := Pkg; Ghdl_Rti_Top.Nbr_Child := Ghdl_Rti_Top.Nbr_Child + 1; end Ghdl_Rti_Add_Package; @@ -33,10 +36,10 @@ package body Grt.Rtis is procedure Ghdl_Rti_Add_Top (Max_Pkg : Ghdl_Index_Type; Pkgs : Ghdl_Rti_Arr_Acc; Top : Ghdl_Rti_Access; - Instance : Address) - is - pragma Unreferenced (Max_Pkg); + Instance : Address) is begin + Max_Top_Pkg := Max_Pkg; + Ghdl_Rti_Top.Parent := Top; Ghdl_Rti_Top.Children := Pkgs; Ghdl_Rti_Top_Instance := Instance; |