Commit e298b5da authored by Sam Steingold's avatar Sam Steingold
Browse files

* lisp/progmodes/etags.el (tags-completion-at-point-function):

Avoid the error when point is inside the pattern.
parent 6e5d1d00
2012-03-21 Sam Steingold <sds@gnu.org>
* progmodes/etags.el (tags-completion-at-point-function):
Avoid the error when point is inside the pattern.
2012-03-21 John Yates <john@yates-sheets.org> (tiny change) 2012-03-21 John Yates <john@yates-sheets.org> (tiny change)
* progmodes/hideshow.el (hs-inside-comment-p): Fix hiding of first * progmodes/hideshow.el (hs-inside-comment-p): Fix hiding of first
......
...@@ -809,10 +809,10 @@ If no tags table is loaded, do nothing and return nil." ...@@ -809,10 +809,10 @@ If no tags table is loaded, do nothing and return nil."
beg) beg)
(when pattern (when pattern
(save-excursion (save-excursion
(search-backward pattern) ;FIXME: will fail if we're inside pattern. (when (search-backward pattern nil t) ; will fail inside pattern
(setq beg (point)) (setq beg (point))
(forward-char (length pattern)) (forward-char (length pattern))
(list beg (point) (tags-lazy-completion-table) :exclusive 'no)))))) (list beg (point) (tags-lazy-completion-table) :exclusive 'no)))))))
(defun find-tag-tag (string) (defun find-tag-tag (string)
"Read a tag name, with defaulting and completion." "Read a tag name, with defaulting and completion."
......
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