GNU bug report logs - #18936
ERC: lexical-binding in 24.4 breaks erc-send-pre-hook

Previous Next

Package: emacs;

Reported by: xristos <xristos <at> sdf.lonestar.org>

Date: Mon, 3 Nov 2014 16:41:01 UTC

Severity: normal

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

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 18936 in the body.
You can then email your comments to 18936 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 bug-gnu-emacs <at> gnu.org:
bug#18936; Package emacs. (Mon, 03 Nov 2014 16:41:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to xristos <xristos <at> sdf.lonestar.org>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Mon, 03 Nov 2014 16:41:02 GMT) Full text and rfc822 format available.

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

From: xristos <xristos <at> sdf.lonestar.org>
To: bug-gnu-emacs <at> gnu.org
Subject: ERC: lexical-binding in 24.4 breaks erc-send-pre-hook
Date: Mon, 03 Nov 2014 10:00:46 -0500
From erc.el, erc-send-pre-hook documentation:

"To change the text that will be sent, set the variable STR which is
used in `erc-send-current-line'."

From erc.el:5272, function `erc-send-input'

    (let ((str input)
	  (erc-insert-this t))
      (setq erc-send-this t)
      (run-hook-with-args 'erc-send-pre-hook input)

STR is dynamically bound.






Reply sent to Stefan Monnier <monnier <at> iro.umontreal.ca>:
You have taken responsibility. (Tue, 04 Nov 2014 20:10:02 GMT) Full text and rfc822 format available.

Notification sent to xristos <xristos <at> sdf.lonestar.org>:
bug acknowledged by developer. (Tue, 04 Nov 2014 20:10:02 GMT) Full text and rfc822 format available.

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

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: xristos <xristos <at> sdf.lonestar.org>
Cc: 18936-done <at> debbugs.gnu.org
Subject: Re: bug#18936: ERC: lexical-binding in 24.4 breaks erc-send-pre-hook
Date: Tue, 04 Nov 2014 15:08:57 -0500
> From erc.el, erc-send-pre-hook documentation:
> "To change the text that will be sent, set the variable STR which is
> used in `erc-send-current-line'."

Indeed.  I installed the patch below which should fix it.


        Stefan


=== modified file 'lisp/erc/erc.el'
--- lisp/erc/erc.el	2014-02-10 01:34:22 +0000
+++ lisp/erc/erc.el	2014-11-04 20:06:00 +0000
@@ -5268,6 +5268,7 @@
       (beep))
     nil)
    (t
+    (defvar str) ;; FIXME: Make it obey the "erc-" prefix convention.
     (let ((str input)
 	  (erc-insert-this t))
       (setq erc-send-this t)





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 03 Dec 2014 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 10 years and 284 days ago.

Previous Next


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