comp.lang.ada
 help / color / mirror / Atom feed
From: Wes Groleau <groleau+news@freeshell.org>
Subject: Re: Why can't you create a out of order subtype?
Date: Thu, 03 Feb 2005 22:42:22 -0500
Date: 2005-02-03T22:42:22-05:00	[thread overview]
Message-ID: <36g98lF516al9U1@individual.net> (raw)
In-Reply-To: <mailman.118.1107435427.527.comp.lang.ada@ada-france.org>

Marius Amado Alves wrote:
>> When I was still in the industry, our Ada vendor
>> implemented Text_IO.End_of_File thusly:
>>
>>    ...
>>    exception
>>       when End_Error => return True;
>> end End_Of_File;
> 
> I'm curious about the "..." part. Was the exception ALWAYS raised?

No, only if you were at end of file.
The ... was an attempt to read from the file,
and if no exception, to put the file back in
its previous state.

The irony is that the purpose of calling the
function before reading is to avoid raising
an exception when you read.



-- 
Wes Groleau

Is it an on-line compliment to call someone a Net Wit ?



  reply	other threads:[~2005-02-04  3:42 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-01 23:51 Why can't you create a out of order subtype? brett_gengler
2005-02-02  0:24 ` Jeffrey Carter
2005-02-02 17:55   ` Marius Amado Alves
2005-02-02 18:50     ` Pascal Obry
2005-02-02 20:22       ` Marius Amado Alves
2005-02-03  4:36       ` Wes Groleau
2005-02-03 12:59         ` Marius Amado Alves
2005-02-04  3:42           ` Wes Groleau [this message]
2005-02-02 19:35     ` Martin Dowie
2005-02-02 20:35       ` Marius Amado Alves
2005-02-02 21:18         ` Martin Dowie
2005-02-03 19:40       ` Robert A Duff
2005-02-03 20:22         ` Marius Amado Alves
2005-02-03 22:05           ` Robert A Duff
2005-02-04  6:49           ` Martin Dowie
2005-02-02 22:26 ` Georg Bauhaus
2005-02-03 23:09 ` Robert A Duff
replies disabled

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