[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#20425: 24.5; completion-at-point not working with prefix starting wi

From: Dmitry Gutov
Subject: bug#20425: 24.5; completion-at-point not working with prefix starting with '(:'
Date: Tue, 28 Apr 2015 06:25:39 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Thunderbird/36.0

On 04/27/2015 03:50 PM, Stefan Monnier wrote:

Thanks.  Indeed, M-TAB at the end of the previous line incorrectly claims
there's no completion, even that this "(:backg" is not a "function
call", so it should complete against "anything we can find".

As a first pass, this patch seems to help (here and in bug#19529, which is apparently a duplicate). It'll also make things worse for macro writers, but the existing `elisp--form-quoted-p' usage doesn't exactly cater to them either.

I should really revisit the "macroexpand all the things for completion" discussion.

diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el
index ad35c48..ca6042a 100644
--- a/lisp/progmodes/elisp-mode.el
+++ b/lisp/progmodes/elisp-mode.el
@@ -480,7 +480,7 @@ It can be quoted, or be inside a quoted form."
       (when (and end (or (not (nth 8 (syntax-ppss)))
                          (eq (char-before beg) ?`)))
         (let ((table-etc
-               (if (not funpos)
+               (if (or (not funpos) (elisp--form-quoted-p beg))
;; FIXME: We could look at the first element of the list and ;; use it to provide a more specific completion table in some ;; cases. E.g. filter out keywords that are not understood by

reply via email to

[Prev in Thread] Current Thread [Next in Thread]