diff options
| author | Chong Yidong | 2010-04-30 19:13:22 -0400 |
|---|---|---|
| committer | Chong Yidong | 2010-04-30 19:13:22 -0400 |
| commit | 27601456d7c2a72b59cc9d4927e86627257d2f46 (patch) | |
| tree | 4b8b67d47650bd78cda4f3405256f07bac7452b2 | |
| parent | afc619439b92209bc437b7764cdf1482784642ab (diff) | |
| download | emacs-27601456d7c2a72b59cc9d4927e86627257d2f46.tar.gz emacs-27601456d7c2a72b59cc9d4927e86627257d2f46.zip | |
* minibuffer.el (tags-completion-at-point-function): Fix return value.
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/minibuffer.el | 12 |
2 files changed, 13 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ddc0fb8e239..ec929a7c58d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2010-04-30 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * minibuffer.el (tags-completion-at-point-function): Fix return | ||
| 4 | value. | ||
| 5 | |||
| 1 | 2010-04-30 Eli Zaretskii <eliz@gnu.org> | 6 | 2010-04-30 Eli Zaretskii <eliz@gnu.org> |
| 2 | 7 | ||
| 3 | * composite.el (compose-region, reference-point-alist): Fix typos | 8 | * composite.el (compose-region, reference-point-alist): Fix typos |
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 80e5f0ad10f..be9b9a524fe 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -1169,6 +1169,7 @@ Currently supported properties are: | |||
| 1169 | `:predicate' a predicate that completion candidates need to satisfy. | 1169 | `:predicate' a predicate that completion candidates need to satisfy. |
| 1170 | `:annotation-function' the value to use for `completion-annotate-function'.") | 1170 | `:annotation-function' the value to use for `completion-annotate-function'.") |
| 1171 | 1171 | ||
| 1172 | (declare-function tags-lazy-completion-table "etags.el" ()) | ||
| 1172 | (defun tags-completion-at-point-function () | 1173 | (defun tags-completion-at-point-function () |
| 1173 | "Using tags, return a completion table for the text around point. | 1174 | "Using tags, return a completion table for the text around point. |
| 1174 | If no tags table is loaded, do nothing and return nil." | 1175 | If no tags table is loaded, do nothing and return nil." |
| @@ -1180,11 +1181,14 @@ If no tags table is loaded, do nothing and return nil." | |||
| 1180 | case-fold-search)) | 1181 | case-fold-search)) |
| 1181 | (pattern (funcall (or find-tag-default-function | 1182 | (pattern (funcall (or find-tag-default-function |
| 1182 | (get major-mode 'find-tag-default-function) | 1183 | (get major-mode 'find-tag-default-function) |
| 1183 | 'find-tag-default)))) | 1184 | 'find-tag-default))) |
| 1185 | beg) | ||
| 1184 | (when pattern | 1186 | (when pattern |
| 1185 | (tags-lazy-completion-table))))) | 1187 | (save-excursion |
| 1186 | 1188 | (search-backward pattern) | |
| 1187 | (declare-function tags-lazy-completion-table "etags.el" ()) | 1189 | (setq beg (point)) |
| 1190 | (forward-char (length pattern)) | ||
| 1191 | (list beg (point) (tags-lazy-completion-table))))))) | ||
| 1188 | 1192 | ||
| 1189 | (defun complete-symbol (&optional arg) | 1193 | (defun complete-symbol (&optional arg) |
| 1190 | "Perform completion on the text around point. | 1194 | "Perform completion on the text around point. |