Re: Bison 3.5.93 released [beta]

Frank Heckenbach <[email protected]>
Newsgroups gmane.comp.parsers.bison.bugs
Message-ID <E1jWfvh-0004ft-7P@goedel>
Akim Demaille wrote:

> First, it was my understanding that diff was supposed to compare
> text files, which, for me, meant ignoring the difference between
> DOS-EOL and Unix-EOL.  The Autoconf documentation reads:
> 
> `cmp'
>      `cmp' performs a raw data comparison of two files, while `diff'
>      compares two text files.  Therefore, if you might compare DOS
>      files, even if only checking whether two files are different, use
>      `diff' to avoid spurious differences due to differences of newline
>      encoding.
> 
> So I believed merely using 'diff' sufficed.  I can confirm that on
> this macOS box, GNU diff does not ignore the difference between \r\n
> and \n, unless I pass the --strip-trailing-cr option.

FYI, I see the same behaviour on Linux. I suppose the intention is
to compare according to what the local system considers "text
files", i.e. \n on Unix/Mac, and either \n or \r\n on DOS/Windows.

So the Autoconf documentation should probably be read in this
context, though it certainly could be clearer on that.

Regards,
Frank
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.