GNU bug report logs -
#24449
Emacs 25.1 RC2: Byte compiler reports error in wrong place.
Previous Next
Reported by: Alan Mackenzie <acm <at> muc.de>
Date: Fri, 16 Sep 2016 11:33:01 UTC
Severity: minor
Found in versions 23.0.91, 23.3.1, 24.0.50, 24.3.1, 25.0.50, 25.1
Done: Alan Mackenzie <acm <at> muc.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
> Date: Fri, 16 Sep 2016 11:31:25 +0000
> From: Alan Mackenzie <acm <at> muc.de>
>
> $ emacs -Q -batch -f batch-byte-compile cc-engine.el
>
> . This outputs the following warning:
>
> In c-forward-decl-or-cast-1:
> cc-engine.el:8105:22:Warning: reference to free variable `eq'
>
> . The use of `eq' on L8105 is entirely correct. The error is at L8636,
> where the following appears:
>
> (and eq context nil
> (match-beginning 1))
>
> . Clearly parentheses around the `eq' form are missing.
>
> The compiler should have output its warning for L8636, not L8105.
Did you look at how the byte compiler determines the line number it
will include in the warning/error message? If you didn't, you should,
because after you do, you will never again wonder why an incorrect
line number is reported. In fact, now that I did look there, I'm
surprised it reports a correct line number at all, let alone as often
as it does. It's sheer luck.
This bug report was last modified 8 years and 326 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.