GNU bug report logs - #16816
24.3.50; erroneous docstring in with-temp-buffer-window

Previous Next

Package: emacs;

Reported by: Nicolas Richard <theonewiththeevillook <at> yahoo.fr>

Date: Wed, 19 Feb 2014 21:31:02 UTC

Severity: minor

Merged with 16882

Found in version 24.3.50

Done: martin rudalics <rudalics <at> gmx.at>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Juanma Barranquero <lekktu <at> gmail.com>
To: martin rudalics <rudalics <at> gmx.at>
Cc: Nicolas Richard <theonewiththeevillook <at> yahoo.fr>, 16816 <at> debbugs.gnu.org
Subject: bug#16816: 24.3.50; erroneous docstring in with-temp-buffer-window
Date: Thu, 27 Feb 2014 16:32:09 +0100
reopen 16816
quit

On Fri, Feb 21, 2014 at 2:08 PM, martin rudalics <rudalics <at> gmx.at> wrote:

> `with-temp-buffer-window' should behave as `with-output-to-temp-buffer'
> in this regard (at least I hope so).  So in revision 116509 I moved the
> evaluation of BODY out of the scope of `with-current-buffer'.  If this
> causes problems, I will revert and use your patch.

This breaks with-help-window. Try

 emacs -Q
 C-x C-h

the help output is inserted in the current buffer (*scratch*, in this case).

This patch fixes it.

=== modified file 'lisp/help.el'
--- lisp/help.el 2014-02-10 01:34:22 +0000
+++ lisp/help.el 2014-02-27 15:29:05 +0000
@@ -1207,7 +1207,8 @@
    (temp-buffer-window-show-hook
     (cons 'help-mode-finish temp-buffer-window-show-hook)))
        (with-temp-buffer-window
- ,buffer-name nil 'help-window-setup (progn ,@body)))))
+ ,buffer-name nil 'help-window-setup
+ (with-current-buffer ,buffer-name ,@body)))))

 ;; Called from C, on encountering `help-char' when reading a char.
 ;; Don't print to *Help*; that would clobber Help history.




This bug report was last modified 11 years and 67 days ago.

Previous Next


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