emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: etags test is broken on MS-Windows


From: Eli Zaretskii
Subject: Re: etags test is broken on MS-Windows
Date: Thu, 21 May 2015 22:54:27 +0300

> Date: Thu, 21 May 2015 12:03:44 -0700
> From: Paul Eggert <address@hidden>
> CC: address@hidden, address@hidden
> 
> On 05/21/2015 09:55 AM, Eli Zaretskii wrote:
> > IOW, the "CRLF->LF translation" that the comment mentions is done on
> > all platforms.  Or am I missing something?
> 
> I was thinking about the case where a source file has mostly lines with 
> LF but a few lines end in CRLF.  E.g., the attached file has a CR at the 
> end of the second line.  In that case, Emacs doesn't strip the trailing 
> CRs on GNU/Linux.  Wouldn't the byte counts get messed up then?

Yes, they would, but it's not fatal, since etags.el searches around
the position for the pattern stated on the tag line.

And of course, in the case you present, the byte counts will be
slightly off on Windows as well.

But the way etags works currently, a file with all of its lines ending
in CRLF will _always_ have all of its byte counts messed up.  Not a
catastrophe, either, but still worse than under my suggestion.

> Come to think of it, one of the etags test cases did that before I 
> removed the CR (and perhaps that was part of the test...).

Yes, one of the files has a single line with CRLF (I thought it was
part of the test as well).



reply via email to

[Prev in Thread] Current Thread [Next in Thread]