-- Demonstrates use of Package containing a private type. WITH text_io, id_handler ; USE text_io, id_handler ; PROCEDURE iddemo IS -- Local Variables : person_id : id_number ; animal_id : id_number ; BEGIN -- iddemo -- allocate values to person_id & animal_id person_id := new_id ; animal_id := new_id ; -- list ids PUT ( "Person Id No. is " ) ; put ( person_id ) ; NEW_LINE ; PUT ( "Animal Id No. is " ) ; put ( animal_id ) ; NEW_LINE ; -- try to explicitly set id number components -- this should generate an error on compilation person_id := ( 1, 2, 3 ) ; animal_id ( 2 ) := 7 ; -- list ids PUT ( "Person Id No. is " ) ; put ( person_id ) ; NEW_LINE ; PUT ( "Animal Id No. is " ) ; put ( animal_id ) ; NEW_LINE ; END iddemo ; -------------------------------------------------------