comp.lang.ada
 help / color / mirror / Atom feed
From: tmoran@bix.com
Subject: Re: Beginners Ada Question on Ada IO.
Date: 1996/12/12
Date: 1996-12-12T00:00:00+00:00	[thread overview]
Message-ID: <58pno8$kan@news2.delphi.com> (raw)


Look up Sequential_IO in your textbook.  Sequential_IO is a generic
which you instantiate with an IO record type - in your case a record
consisting of a single byte.
  BTW, I note you have an integer with range 0 .. 255.  The compiler
will not necessarily store that as 8 bits, and the record you write
won't necessarily be only 8 bits, unless you define a type and
use a 'size clause to force it to 8 bits.
  Also, your C-Ada code does a new_line; do you really want to put
CRs/LFs in your binary file?  If you use Sequential_IO you will have
to do that explicitly by writing a byte (or two) with the right
values, rather than letting the system mark end-of-line according
to its own conventions.




             reply	other threads:[~1996-12-12  0:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-12-12  0:00 tmoran [this message]
  -- strict thread matches above, loose matches on Subject: below --
1996-12-11  0:00 Beginners Ada Question on Ada IO Konstantin Gromov
1996-12-11  0:00 ` Stephen Leake
1996-12-11  0:00   ` Larry Kilgallen
replies disabled

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