Subject: Re: bug#17007: 24.3.50; describe-key/function evaluates documentation function in the wrong buffer

From: martin rudalics <[email-masked]>
Date: Sun, 16 Mar 2014 11:01:39 +0100

> It's simpler if I give you an emacs -Q recipe, right? In your *scratch*
 > buffer:
 >
 >     (defun foo ())
 >     (defun foo-doc ()
 >       (format "Foo does nothing, and by the way your tab does `%s'"
 >             	     (key-binding "\t")))
 >     (put 'foo 'function-documentation '(foo-doc))
 >     (describe-function 'foo)
 >
 > This fails on the latest Emacs, i.e. the last line returned by the last
 > form is
 >
 >     "Foo does nothing, and by the way your tab does `forward-button'"
 >
 > Whereas it should report, as in Emacs 24.3
 >
 >     "Foo does nothing, and by the way your tab does `indent-for-tab-command'"

Should work now as intended.  Please try again.

Thanks, martin