--  A generic child of a generic, instantiated through an instance of its parent (RM
--  10.1.1(19), 12.3): `Int_Stacks.Peek` sees `Int_Stacks`' declarations as its parent's.
with Ada.Text_IO;
with Int_Stacks;
with Stacks.Peek;
procedure Main is
   package Peek is new Int_Stacks.Peek;
   S : Int_Stacks.Stack;
begin
   Ada.Text_IO.Put_Line (Natural'Image (Peek.Top_Index (S)));
end Main;
