From: "Björn Lundin" <b.f.lundin@gmail.com>
Subject: Re: Error "exception not permitted here" when putting EXCEPTION in a loop
Date: Sat, 18 Jul 2015 15:56:23 +0200
Date: 2015-07-18T15:56:23+02:00 [thread overview]
Message-ID: <modlp5$rat$1@dont-email.me> (raw)
In-Reply-To: <f6160b36-25b7-4200-9739-b92e29557903@googlegroups.com>
On 2015-07-18 14:41, Trish Cayetano wrote:
> Hello Björn,
>
> I don't need the inner loop after all.
> I removed the inner loop but it still run in infinite loops.
it runs fine as long as you do not enter a non-digit.
Then it seems like the call to
Ada.Integer_Text_IO.Get(option);
does not clear the buffer.
if fed a character, Data_error is raised - which is correct.
But the next time the code enters the loop, it seems it does
not wait for input again.
It raises the data_error again, and the infinite loop is there.
Seems like a compiler bug to me, but the behavior of *text_io.get
has surprised me before.
--
Björn
next prev parent reply other threads:[~2015-07-18 13:56 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-17 15:47 Error "exception not permitted here" when putting EXCEPTION in a loop Trish Cayetano
2015-07-17 15:56 ` David Botton
2015-07-17 15:58 ` G.B.
2015-07-18 8:14 ` Trish Cayetano
2015-07-18 10:08 ` Björn Lundin
2015-07-18 12:41 ` Trish Cayetano
2015-07-18 13:56 ` Björn Lundin [this message]
2015-07-18 14:08 ` Niklas Holsti
2015-07-18 14:56 ` Björn Lundin
2015-07-18 14:32 ` Trish Cayetano
2015-07-18 14:59 ` Björn Lundin
2015-07-18 16:09 ` Dennis Lee Bieber
2015-07-18 18:11 ` Niklas Holsti
2015-07-18 21:16 ` Dennis Lee Bieber
2015-07-17 16:02 ` Björn Lundin
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox