[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bug in 'wc -l'
From: |
era+gmane |
Subject: |
Re: bug in 'wc -l' |
Date: |
06 Feb 2004 16:58:29 +0200 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 |
On Fri, 6 Feb 2004 13:05:09 +0100 (MET), Alfred M. Szmidt
<address@hidden> posted to gmane.comp.gnu.core-utils.bugs:
> I am sending you a patch to solve a 'problem' at the wc program.
> When used with -l option (to count the number of lines) the last
> line isn't counted.
> It counts occurences of '\n' (i.e. newline). So I guess that the
> behaviour is correct.
If that's your definition of a line, obviously. However, the poster is
probably right that the last line of a file should count as a line
even if it lacks a final newline.
> Well, if it doesn't end with a newline (\n) then it isn't really a
> line...
Is too. Is not. Is too. Your reasoning smacks of a circular argument,
anyway (nothing personal :-)
/* era */
--
formail -s procmail <http://www.iki.fi/era/spam/ >http://www.euro.cauce.org/
cat | more | cat<http://www.iki.fi/era/unix/award.html>http://www.debian.org/