comp.lang.ada
 help / color / mirror / Atom feed
From: Colin_Paul_Gloster@ACM.org (Colin Paul Gloster)
Subject: Re: What does "raised ADA.IO_EXCEPTIONS.DATA_ERROR" mean?
Date: 27 Jan 2003 13:05:14 GMT
Date: 2003-01-27T13:05:14+00:00	[thread overview]
Message-ID: <slrnb3abka.ph5.Colin_Paul_Gloster@camac.dcu.ie> (raw)
In-Reply-To: 397fbe9e.0301270232.39fb506a@posting.google.com

Fatafa said today:
"I ran a compiled Ada program and got back the error :

raised ADA.IO_EXCEPTIONS.DATA_ERROR

Does anyone know what this means?"

When giving input to your program, you probably gave it something it was
not designed to (e.g. maybe it needed a number and you typed in text).

From HTTP://WWW.AdaIC.org/standards/95lrm/html/RM-A-13.html :

"[..]

The exception Data_Error can be propagated by the procedure Read (or by
the Read attribute) if the element read cannot be
interpreted as a value of the required subtype. This exception is also
propagated by a procedure Get (defined in the package
Text_IO) if the input character sequence fails to satisfy the required
syntax, or if the value input does not belong to the range of the
required subtype.

[..]"



  reply	other threads:[~2003-01-27 13:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-27 10:32 What does "raised ADA.IO_EXCEPTIONS.DATA_ERROR" mean? Fatafa
2003-01-27 13:05 ` Colin Paul Gloster [this message]
2003-01-27 18:33 ` Stephen Leake
  -- strict thread matches above, loose matches on Subject: below --
2003-01-27 11:18 Grein, Christoph
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox