2 -- { dg-options "-O -gnatn" }
4 with Ada
.Text_IO
; use Ada
.Text_IO
;
6 with Controlled6_Pkg
.Iterators
;
8 procedure Controlled6
is
10 type String_Access
is access String;
12 package My_Q
is new Controlled6_Pkg
(String_Access
);
13 package My_Iterators
is new My_Q
.Iterators
(0);
16 Iterator
: Iterator_Type
:= Find
;
20 exit when Is_Null
(Iterator
);
21 Put
(Current
(Iterator
).all & ' ');