From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,680f4c169f5fad47,start X-Google-Attributes: gid103376,public From: Scott Ingram Subject: Raising IO_EXCEPTIONS.END_ERROR in a loop Date: 1997/11/19 Message-ID: <3472EEAE.65B43D71@silver.jhuapl.edu>#1/1 X-Deja-AN: 290728094 Organization: Johns Hopkins University Applied Physics Laboratory Newsgroups: comp.lang.ada Date: 1997-11-19T00:00:00+00:00 List-Id: The following fragment compiles, and even runs correctly through one iteration but blows up when re-reading a string from standard input. The exception that is raised makes me think that the string variable used is still visible the second time through-- but shouldn't it pass out of existence at the end of the block? or what am I misunderstanding? procedure somesuch is begin loop exit when Continue = 'n' or Continue = 'N'; Get_Variable: declare Variable_Name : String (1..OS_Line_Length); Name_Length : Natural; begin --Get_Variable Put ("Enter the name of the variable to examine: "); Get_Line (Variable_Name, Name_Length); Put_Line ("The variable is set to " & Variable_Name(1..Name_Length)); end Get_Variable; Put ("Examine another (y|Y)? "); Get_Immediate (Continue); end loop; end somesuch; -- Scott Ingram Sonar Processing and Analysis Laboratory Johns Hopkins University Applied Physics Laboratory