On Wed, 28 Nov 2001, Van Snyder wrote:
> In the present draft of the Fortran 2000 standard, ACHAR(10) is specified
> to cause a new-line when output using stream access. But stream access
> isn't available for internal files.
That's interesting, and clever if it works. My understanding (I hope
someone will correct me if I'm wrong) is that "newline" means
on Unix/Linux: LF i.e. achar(10)
on Macintosh: CR i.e. achar(13)
on Windows: CR LF i.e. achar(13) // achar(10)
So the achar(10) solution to be used by Catherine will not be very
portable, nor will the use of achar(10) in stream output in Fortran 2000,
unless the compiler does some clever substitutions. Does the Draft
Standard really specify that?
I've never used C except on Unix/Linux boxes, so have no idea what happens
on other platforms: if you use "/n" does the C compiler indeed translate
it into the appropriate character or pair of characters according to the
platform, or is C as unportable as Fortran in this instance?
--
Clive Page, /"\ ASCII ribbon
Dept of Physics & Astronomy, \ / campaign against
University of Leicester. X HTML mail
U.K. / \ and postings
|