with ada.text_io;
procedure f is
--1 can't put instantiation here because we don't know
what color is
type color is (red, green, blue, violet,
abracadabraexpialidoshis);
--2 can go here
--package colorIO is new ada.text_io.enumeration_IO (enum
=> color);
favoriteColor : color;
--3 can go here
--package colorIO is new ada.text_io.enumeration_IO (enum
=> color);
--4 package
colorIO is new ada.text_io.enumeration_IO (enum => color); can't go here
-- declarations must come before begin
favoriteColor:=abracadabraexpialidoshis
;
colorIO.put
(favoriteColor);
end f;