retitle 608515 file: FORTRAN magic is woefully inaccurate and frequently used
found 608515 5.04-5
merge 593928 608515
merge 605104 608515
kthxbye

On Fri, Dec 31, 2010 at 10:37:32PM +0100, Jakub Wilk wrote:
> tags 608515 - patch
> # misidentification is by no means RC 
> severity 608515 normal

This is RC by virtue of the fact that it's breaking debhelper's manpage
installaation which breaks other packages, including generating FTBFS
bugs in at least TenDRA.  I've not raised the severity yet but would
really expect that this would be addressed in some fashion.

Looking at the other outstanding bugs in the package it appears that the
new FORTRAN magic has some serious problems - there's a couple of other
bugs, including 593928 which is also about false positives, both of
which have apparently been completely ignored.

The current magic for FORTRAN is:

0       regex/100       \^[Cc][\ \t]    FORTRAN program

One the one hand this seems excesively generic; it appears that if any
of the first 100 lines of a file begins with the character C or c
followed by a blank will be identified as FORTRAN - this is happening
for TenDRA because it talks about being a C compiler.

On the other hand since this is just looking for a subset of FORTRAN
comments it'll only match FORTRAN source with FORTRAN 77 style comments
in the first 100 lines which is going to miss going to miss rather a lot
of stuff, including anything using one of the other comment initators (*
was also used, for example, and the standard for FORTRAN 90 is !).

With the current code I'd suggest as a minimal bodge updating the magic
so that the FORTRAN matches are one of the last things matched (so that
other matches will take priority, at the minute I'd expect FORTRAN to
turn up relatively early due to the postition of f within the alphabet),
or even just removing the FORTRAN magic entirely for the time being as
it's at best weakly accurate.  

Obviously the quality of the magic should be improved but that's a much
more invasive change; looking at the changelog it appears that there
used to be a hard coded (rather than magic based) test for this which
appears to have worked much better, possibly simply as a result of the
sorting.  Sadly upstream doesn't have an immediately discoverable public
VCS to trawl.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to