461 |
(defun variable-at-point () |
(defun variable-at-point () |
462 |
"Return the bound variable symbol found around point. |
"Return the bound variable symbol found around point. |
463 |
Return 0 if there is no such symbol." |
Return 0 if there is no such symbol." |
464 |
(condition-case () |
(or (condition-case () |
465 |
(with-syntax-table emacs-lisp-mode-syntax-table |
(with-syntax-table emacs-lisp-mode-syntax-table |
466 |
(save-excursion |
(save-excursion |
467 |
(or (not (zerop (skip-syntax-backward "_w"))) |
(or (not (zerop (skip-syntax-backward "_w"))) |
468 |
(eq (char-syntax (following-char)) ?w) |
(eq (char-syntax (following-char)) ?w) |
469 |
(eq (char-syntax (following-char)) ?_) |
(eq (char-syntax (following-char)) ?_) |
470 |
(forward-sexp -1)) |
(forward-sexp -1)) |
471 |
(skip-chars-forward "'") |
(skip-chars-forward "'") |
472 |
(let ((obj (read (current-buffer)))) |
(let ((obj (read (current-buffer)))) |
473 |
(or (and (symbolp obj) (boundp obj) obj) |
(and (symbolp obj) (boundp obj) obj)))) |
474 |
0)))) |
(error nil)) |
475 |
(error 0))) |
(let* ((str (find-tag-default)) |
476 |
|
(obj (if str (read str)))) |
477 |
|
(and (symbolp obj) (boundp obj) obj)) |
478 |
|
0)) |
479 |
|
|
480 |
;;;###autoload |
;;;###autoload |
481 |
(defun describe-variable (variable &optional buffer) |
(defun describe-variable (variable &optional buffer) |