Commit e91b8e7e authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(variable-at-point, function-called-at-point): Fix revious changes.

parent 8d9583b0
......@@ -445,9 +445,10 @@ C-w print information on absence of warranty for GNU Emacs."
(error nil))
(condition-case ()
(save-excursion
(and (or (eq (char-syntax (preceding-char)) ?_)
(eq (char-syntax (preceding-char)) ?w))
(forward-sexp -1))
(or (not (zerop (skip-syntax-backward "_w")))
(eq (char-syntax (following-char)) ?w)
(eq (char-syntax (following-char)) ?_)
(forward-sexp -1))
(skip-chars-forward "'")
(let ((obj (read (current-buffer))))
(and (symbolp obj) (fboundp obj) obj)))
......@@ -542,9 +543,10 @@ C-w print information on absence of warranty for GNU Emacs."
(defun variable-at-point ()
(condition-case ()
(save-excursion
(and (or (eq (char-syntax (preceding-char)) ?_)
(eq (char-syntax (preceding-char)) ?w))
(forward-sexp -1))
(or (not (zerop (skip-syntax-backward "_w")))
(eq (char-syntax (following-char)) ?w)
(eq (char-syntax (following-char)) ?_)
(forward-sexp -1))
(skip-chars-forward "'")
(let ((obj (read (current-buffer))))
(and (symbolp obj) (boundp obj) obj)))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment