GNU bug report logs - #8518
24.0.50; 'byte-compile-error-on-warn' no effect on 'defvar ignored because X is let-bound' warning

Previous Next

Package: emacs;

Reported by: David Engster <deng <at> randomsample.de>

Date: Mon, 18 Apr 2011 09:24:02 UTC

Severity: minor

Found in version 24.0.50

Done: David Engster <deng <at> randomsample.de>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 8518 in the body.
You can then email your comments to 8518 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8518; Package emacs. (Mon, 18 Apr 2011 09:24:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to David Engster <deng <at> randomsample.de>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 18 Apr 2011 09:24:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: David Engster <deng <at> randomsample.de>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.0.50;
	'byte-compile-error-on-warn' no effect on 'defvar ignored because X
	is let-bound' warning
Date: Mon, 18 Apr 2011 11:22:40 +0200
Here's the recipe:

* Create files

--- test.el ----
 (eval-when-compile
   (let ((test-something nil))
     (require 'test2)))
----------------

--- test2.el ----
 (defvar test-something t)
 (provide 'test2)
-----------------

* Now byte-compile the first file with

emacs --batch -L . --eval "(setq byte-compile-error-on-warn t)" -f batch-byte-compile test.el

Output will be:

Warning: defvar ignored because test-something is let-bound
Wrote /home/user/test.elc

with an exit code 0.

* Expected behavior: batch-byte-compile should return the warning as
  an error with exit code >0.


This was tested with Emacs bzr revno. 103887.

-David




Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#8518; Package emacs. (Mon, 18 Apr 2011 17:38:01 GMT) Full text and rfc822 format available.

Message #8 received at 8518 <at> debbugs.gnu.org (full text, mbox):

From: Glenn Morris <rgm <at> gnu.org>
To: David Engster <deng <at> randomsample.de>
Cc: 8518 <at> debbugs.gnu.org
Subject: Re: bug#8518: 24.0.50;
	'byte-compile-error-on-warn' no effect on 'defvar ignored because X
	is let-bound' warning
Date: Mon, 18 Apr 2011 13:37:45 -0400
The warning does not come from the compiler, it comes from when the
code is evaluated. You get the same result with:

emacs -batch -L . -l ./test.el




Reply sent to David Engster <deng <at> randomsample.de>:
You have taken responsibility. (Tue, 19 Apr 2011 05:41:02 GMT) Full text and rfc822 format available.

Notification sent to David Engster <deng <at> randomsample.de>:
bug acknowledged by developer. (Tue, 19 Apr 2011 05:41:02 GMT) Full text and rfc822 format available.

Message #13 received at 8518-done <at> debbugs.gnu.org (full text, mbox):

From: David Engster <deng <at> randomsample.de>
To: Glenn Morris <rgm <at> gnu.org>
Cc: 8518-done <at> debbugs.gnu.org
Subject: Re: bug#8518: 24.0.50;
	'byte-compile-error-on-warn' no effect on 'defvar ignored because X
	is let-bound' warning
Date: Tue, 19 Apr 2011 07:39:50 +0200
Glenn Morris writes:
> The warning does not come from the compiler, it comes from when the
> code is evaluated. You get the same result with:
>
> emacs -batch -L . -l ./test.el

Oh, you're right, of course. Sorry for the noise.

-David




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 17 May 2011 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 14 years and 32 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.