[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r100095: * minibuffer.el (tags-comple
From: |
Chong Yidong |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r100095: * minibuffer.el (tags-completion-at-point-function): Fix return value. |
Date: |
Fri, 30 Apr 2010 19:13:22 -0400 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 100095
committer: Chong Yidong <address@hidden>
branch nick: trunk
timestamp: Fri 2010-04-30 19:13:22 -0400
message:
* minibuffer.el (tags-completion-at-point-function): Fix return value.
modified:
lisp/ChangeLog
lisp/minibuffer.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2010-04-30 12:16:13 +0000
+++ b/lisp/ChangeLog 2010-04-30 23:13:22 +0000
@@ -1,3 +1,8 @@
+2010-04-30 Chong Yidong <address@hidden>
+
+ * minibuffer.el (tags-completion-at-point-function): Fix return
+ value.
+
2010-04-30 Eli Zaretskii <address@hidden>
* composite.el (compose-region, reference-point-alist): Fix typos
=== modified file 'lisp/minibuffer.el'
--- a/lisp/minibuffer.el 2010-04-29 15:32:11 +0000
+++ b/lisp/minibuffer.el 2010-04-30 23:13:22 +0000
@@ -1169,6 +1169,7 @@
`:predicate' a predicate that completion candidates need to satisfy.
`:annotation-function' the value to use for `completion-annotate-function'.")
+(declare-function tags-lazy-completion-table "etags.el" ())
(defun tags-completion-at-point-function ()
"Using tags, return a completion table for the text around point.
If no tags table is loaded, do nothing and return nil."
@@ -1180,11 +1181,14 @@
case-fold-search))
(pattern (funcall (or find-tag-default-function
(get major-mode 'find-tag-default-function)
- 'find-tag-default))))
+ 'find-tag-default)))
+ beg)
(when pattern
- (tags-lazy-completion-table)))))
-
-(declare-function tags-lazy-completion-table "etags.el" ())
+ (save-excursion
+ (search-backward pattern)
+ (setq beg (point))
+ (forward-char (length pattern))
+ (list beg (point) (tags-lazy-completion-table)))))))
(defun complete-symbol (&optional arg)
"Perform completion on the text around point.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r100095: * minibuffer.el (tags-completion-at-point-function): Fix return value.,
Chong Yidong <=