all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#16792: 24.3.50; wish: following a variable name should show the value from initial buffer
@ 2014-02-18 15:03 Nicolas Richard
  2014-02-18 16:45 ` Stefan Monnier
  0 siblings, 1 reply; 3+ messages in thread
From: Nicolas Richard @ 2014-02-18 15:03 UTC (permalink / raw)
  To: 16792

Hello,

Consider the following~:

(with-current-buffer (get-buffer-create "foo")
  ;; change a variable locally
  (setq-local beginning-of-defun-function #'beginning-of-line)
  ;; describe a function that references the above variable
  (describe-function 'beginning-of-defun)
  (switch-to-buffer "*Help*")
  ;; go to the reference and follow it
  (search-forward "beginning-of-defun-functio")
  (execute-kbd-macro (kbd "RET")))

The second line is:
: Its value is nil

I somewhat expected to see:
: Its value is beginning-of-line
: Local in buffer foo; global value is nil

If the old buffer is killed before following the reference, I guess I'd
like to be warned about it and see the global value instead.

What do you think ?

-- 
Nico.





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#16792: 24.3.50; wish: following a variable name should show the value from initial buffer
  2014-02-18 15:03 bug#16792: 24.3.50; wish: following a variable name should show the value from initial buffer Nicolas Richard
@ 2014-02-18 16:45 ` Stefan Monnier
  2021-05-30  4:48   ` Lars Ingebrigtsen
  0 siblings, 1 reply; 3+ messages in thread
From: Stefan Monnier @ 2014-02-18 16:45 UTC (permalink / raw)
  To: Nicolas Richard; +Cc: 16792

So you're saying that describe-function should remember in which buffer
it was invoked, in case we use describe-variable from the resulting
*Help* buffer.

It's not a terribly bad idea, but to the extent that functions can't be
buffer-local, it'd be an ad-hoc hack.  It wouldn't be the first ad-hoc
hack by the long shot, but I'm not sure I'd like to add this one.


        Stefan





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#16792: 24.3.50; wish: following a variable name should show the value from initial buffer
  2014-02-18 16:45 ` Stefan Monnier
@ 2021-05-30  4:48   ` Lars Ingebrigtsen
  0 siblings, 0 replies; 3+ messages in thread
From: Lars Ingebrigtsen @ 2021-05-30  4:48 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Nicolas Richard, 16792

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> It's not a terribly bad idea, but to the extent that functions can't be
> buffer-local, it'd be an ad-hoc hack.  It wouldn't be the first ad-hoc
> hack by the long shot, but I'm not sure I'd like to add this one.

No, it sounds somewhat confusing, so I'm closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-05-30  4:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-02-18 15:03 bug#16792: 24.3.50; wish: following a variable name should show the value from initial buffer Nicolas Richard
2014-02-18 16:45 ` Stefan Monnier
2021-05-30  4:48   ` Lars Ingebrigtsen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.