From: dewar@merv.cs.nyu.edu (Robert Dewar)
Subject: Re: GNAT's Text_IO & empty files
Date: 1998/07/07
Date: 1998-07-07T00:00:00+00:00 [thread overview]
Message-ID: <dewar.899850671@merv> (raw)
In-Reply-To: 35A21B66.1509490B@cl.cam.ac.uk
Markus says
<<Having just read RM A.10 M-'7, I think the Ada standard is badly
formulated here. It is not clear how a file or a page with zero
lines or a file with zero pages has to be encoded. The standard writes
that a file is a sequence of pages and a page is a sequence of lines,
but it does not handle the obvious border case of zero-length
sequences adequatly. It would have been better to write just that
every line terminates with a line terminator, and every page
terminates with a page terminator, and then everything would have
been clear and consistent. With a bit good will, the Ada RM language
can even be interpreted that way.>>
I disagree. The RM deliberately stays out of the business of describing
how a file is encoded, and that is as it should be, since the appropriate
encoding is most certainly system dependent. It just describes a set of
high level features, and you can implement them anyway you want. People
often assume for instance that the codes in a Text_IO file will match
those of Standard.Character, but nowhere in the RM is there such a
requirement, and a compiler that always used Unicode for Text_IO files
is perfectly well conforming!
next prev parent reply other threads:[~1998-07-07 0:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
1998-07-06 0:00 GNAT's Text_IO & empty files Gautier de Montmollin
1998-07-06 0:00 ` Robert Dewar
1998-07-07 0:00 ` Markus Kuhn
1998-07-07 0:00 ` Michael F Brenner
1998-07-07 0:00 ` Robert Dewar [this message]
1998-07-07 0:00 ` Markus Kuhn
1998-07-07 0:00 ` Samuel Tardieu
1998-07-08 0:00 ` Aaro Koskinen
1998-07-09 0:00 ` Samuel Tardieu
1998-07-09 0:00 ` Gautier.DeMontmollin
1998-07-07 0:00 ` Gautier
1998-07-08 0:00 ` dennison
1998-07-07 0:00 ` Gautier
1998-07-07 0:00 ` Robert Dewar
1998-07-07 0:00 ` Robert I. Eachus
1998-07-06 0:00 ` Pascal MALAISE
1998-07-07 0:00 ` Kevin Radke
1998-07-07 0:00 ` Gautier
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox