[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fw: probable bug/shortcoming of gawk v3.0.3
From: |
Aharon Robbins |
Subject: |
Re: Fw: probable bug/shortcoming of gawk v3.0.3 |
Date: |
Tue, 13 Mar 2001 14:38:15 +0200 |
> Date: Thu, 8 Mar 2001 22:56:09 -0800
> From: David Inman=20
> To: address@hidden
> Subject: probable bug/shortcoming of gawk v3.0.3
>
> Kind Sir or Madam:
>
> Help! Please!
>
> On Win98SE with Cygwin's GAWK V3.0.3 (latest I could find compiled):
> 1. Create a file with one character, say 'a' and NO '\n' following it.
> You may find this tricky to do since many programs just slap a '\n'
> on the end when you don't want one.
> 2. Create a file as above with the letter 'a' but include the '\n' at > the
> end of the line.
> 3. Read the files with getline. (The files were not specified on the >
> command line
> invoking gawk.)
>
> I have not found a way to differentiate between these two files when >
> reading
> the files within GAWK by comparing what is read. I need to know if a > '\n'
> was part of the last line of the file or not and the getline functions >
> seems to
> treat them as if they were identical. I played with RS, ORS, FS, ... to > no
> avail.
>
> Thanks,
>
> Dave Inman
> address@hidden
Check RT. If RT = "" then there was no '\n' at the end of the line.
Arnold
--
Aharon (Arnold) Robbins --- Pioneer Consulting Ltd. address@hidden
P.O. Box 354 Home Phone: +972 8 979-0381 Fax: +1 603 761-6761
Nof Ayalon Cell Phone: +972 51 297-545 (See www.efax.com)
D.N. Shimshon 99785 Laundry increases exponentially in the
ISRAEL number of children. -- Miriam Robbins