mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-11 16:08:13 +00:00
(describe-variable): Report whether var is local in this buf.
This commit is contained in:
parent
5afc7fb0ba
commit
7e76ae2395
12
lisp/help.el
12
lisp/help.el
@ -456,7 +456,17 @@ Returns the documentation as a string, also."
|
||||
(if (not (boundp variable))
|
||||
(princ "void.")
|
||||
(prin1 (symbol-value variable)))
|
||||
(terpri) (terpri)
|
||||
(terpri)
|
||||
(let ((locals (buffer-local-variables))
|
||||
is-local)
|
||||
(while locals
|
||||
(if (or (eq variable (car locals))
|
||||
(eq variable (car-safe (car locals))))
|
||||
(setq is-local t locals nil))
|
||||
(setq locals (cdr locals)))
|
||||
(if is-local
|
||||
(princ (format "Local in buffer %s\n" (buffer-name)))))
|
||||
(terpri)
|
||||
(princ "Documentation:")
|
||||
(terpri)
|
||||
(let ((doc (documentation-property variable 'variable-documentation)))
|
||||
|
Loading…
Reference in New Issue
Block a user