aboutsummaryrefslogtreecommitdiffstats
path: root/src/synth/elab-vhdl_annotations.adb
diff options
context:
space:
mode:
Diffstat (limited to 'src/synth/elab-vhdl_annotations.adb')
-rw-r--r--src/synth/elab-vhdl_annotations.adb5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/synth/elab-vhdl_annotations.adb b/src/synth/elab-vhdl_annotations.adb
index 9475ac940..84bb6e02e 100644
--- a/src/synth/elab-vhdl_annotations.adb
+++ b/src/synth/elab-vhdl_annotations.adb
@@ -479,15 +479,16 @@ package body Elab.Vhdl_Annotations is
Nbr_Objects => 0,
Pkg_Slot => Invalid_Object_Slot,
Pkg_Parent => null);
+ Set_Info (Decl, Package_Info);
if Is_Inst or else not Is_Uninstantiated_Package (Decl) then
+ -- Allocate a slot in the parent block.
Block_Info.Nbr_Objects := Block_Info.Nbr_Objects + 1;
+ -- Link with parent.
Package_Info.Pkg_Slot := Block_Info.Nbr_Objects;
Package_Info.Pkg_Parent := Block_Info;
end if;
- Set_Info (Decl, Package_Info);
-
if Is_Inst then
Annotate_Interface_List
(Package_Info, Get_Generic_Chain (Decl), True);