bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#22288: 25.0.50; Incorrect line and column number in byte-compilation


From: Alan Mackenzie
Subject: bug#22288: 25.0.50; Incorrect line and column number in byte-compilation warning
Date: Sat, 22 Jan 2022 18:16:58 +0000

Hello Everybody.

This bug has just been fixed in master by merging in branch
scratch/correct-warning-pos.

-- 
Alan Mackenzie (Nuremberg, Germany).

On Fri, Jan 01, 2016 at 10:54:24 -0500, Clément Pit--Claudel wrote:
> Hi all,

> The byte-compiler doesn't always report the right line and column numbers. 
> For example for the following program in test.el:

> (defun test ()
>   (let (a))
>   a)

> Running M-x byte-compile-file RET test.el RET yields:

> > Compiling file /home/clement/test.el at Fri Jan  1 10:48:41 2016

> > In test:
> > test.el:2:9:Warning: reference to free variable ‘a’

> The correct warning would be

> > test.el:3:2:Warning: reference to free variable ‘a’

> Note that the following program gives the right error:

> (defun test ()
>   (let (b))
>   a)

> > test.el:3:3:Warning: reference to free variable ‘a’

> Although one might argue that it should be

> > test.el:3:2:Warning: reference to free variable ‘a’

> (that is, column 2, not 3) given that Emacs starts counting columns at 0.

> Cheers,
> Clément.

> In GNU Emacs 25.0.50.8 (x86_64-unknown-linux-gnu, GTK+ Version 3.10.8)
>  of 2015-12-29 built on clem-w50-mint
> Repository revision: a21bb238ce7bcc9c13a9cf66db77918304daa2fc
> Windowing system distributor 'The X.Org Foundation', version 11.0.11501000
> System Description:   Linux Mint 17.2 Rafaela





reply via email to

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