Index: src/natools-static_hash_maps.adb ================================================================== --- src/natools-static_hash_maps.adb +++ src/natools-static_hash_maps.adb @@ -350,10 +350,19 @@ Ada.Text_IO.Put (Spec_File, "private "); end if; Ada.Text_IO.Put_Line (Spec_File, "package " & To_String (Pkg.Name) & " is"); Ada.Text_IO.New_Line (Spec_File); + + declare + Declarations : constant String := To_String (Pkg.Extra_Declarations); + begin + if Declarations'Length > 0 then + Ada.Text_IO.Put_Line (Spec_File, Declarations); + Ada.Text_IO.New_Line (Spec_File); + end if; + end; Current_Stage := Public_Spec; Map_Pos := 0; Pkg.Maps.Iterate (Query'Access); @@ -501,10 +510,18 @@ Description : in String) is begin Self.Description := Hold (Description); end Set_Description; + + procedure Set_Extra_Declarations + (Self : in out Map_Package; + Declarations : in String) is + begin + Self.Extra_Declarations := Hold (Declarations); + end Set_Extra_Declarations; + procedure Set_Private_Child (Self : in out Map_Package; Private_Child : in Boolean := True) is begin Index: src/natools-static_hash_maps.ads ================================================================== --- src/natools-static_hash_maps.ads +++ src/natools-static_hash_maps.ads @@ -87,10 +87,14 @@ procedure Set_Description (Self : in out Map_Package; Description : in String); + procedure Set_Extra_Declarations + (Self : in out Map_Package; + Declarations : in String); + procedure Set_Private_Child (Self : in out Map_Package; Private_Child : in Boolean := True); procedure Add_Map (Self : in out Map_Package; Map : in Map_Description); @@ -146,10 +150,11 @@ (Map_Description); type Map_Package is record Name : String_Holder; Description : String_Holder; + Extra_Declarations : String_Holder; Priv : Boolean; Maps : Map_Lists.List; end record; end Natools.Static_Hash_Maps;