From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Vitalie Spinu Newsgroups: gmane.emacs.devel Subject: Re: Completion with (:exclusive 'no) is called twice, and doesn't pass over on sole completion. Date: Mon, 19 Mar 2012 09:35:10 +0100 Organization: EUR Message-ID: <874ntlng3l.fsf@gmail.com> References: <87haxoyff9.fsf@gmail.com> <87sjh8wdbw.fsf@gmail.com> <87haxmx0o7.fsf@gmail.com> <87d38aw8u1.fsf@gmail.com> <87ehspogzt.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1332146149 21449 80.91.229.3 (19 Mar 2012 08:35:49 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 19 Mar 2012 08:35:49 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Mar 19 09:35:48 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1S9Y48-0001w5-H2 for ged-emacs-devel@m.gmane.org; Mon, 19 Mar 2012 09:35:44 +0100 Original-Received: from localhost ([::1]:59807 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S9Y47-0001f7-Jr for ged-emacs-devel@m.gmane.org; Mon, 19 Mar 2012 04:35:43 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:46249) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S9Y3y-0001ed-1R for emacs-devel@gnu.org; Mon, 19 Mar 2012 04:35:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1S9Y3n-00011g-Um for emacs-devel@gnu.org; Mon, 19 Mar 2012 04:35:33 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:47738) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1S9Y3n-00011a-O1 for emacs-devel@gnu.org; Mon, 19 Mar 2012 04:35:23 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1S9Y3l-0001gn-QP for emacs-devel@gnu.org; Mon, 19 Mar 2012 09:35:21 +0100 Original-Received: from e138158.upc-e.chello.nl ([213.93.138.158]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 19 Mar 2012 09:35:21 +0100 Original-Received: from spinuvit by e138158.upc-e.chello.nl with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 19 Mar 2012 09:35:21 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 43 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: e138158.upc-e.chello.nl User-Agent: Gnus/5.130004 (Ma Gnus v0.4) Emacs/24.0.94 (gnu/linux) Cancel-Lock: sha1:FSNzb0qSc00I/PCyFji2vgbSCGw= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:149126 Archived-At: >>>> Stefan Monnier >>>> on Sun, 18 Mar 2012 20:53:11 -0400 wrote: >> or expansions a la yas. > I guess you're referring to some part of yasnippet, but I don't know > which part, nor why it is related to completion-at-point-functions. Yes, I mean the expansion of abbreviations at point, like yasnippet does. But, it looks like you don't consider it as a completion in the first place. >> So you would still need a separate list for those. > As explained, partial-completion is another problem. As for abbrev-like > "completion+expansion", I don't see why it can't work with AC (and if > it can't work, the completion-at-point-function can return some data > in its `props' making it clear it can't be used for AC). Hmm, ... right, still cannot get used to the concept. >> And the old argument still stands - would the user like to have the same >> redundant list of completion functions for C-M-i and popup menu? > I don't see why not. Tho, for completions like etags-completion or > dabbrev-completion, i.e. forms of completions which don't actually know > whether the candidates they return are actually relevant at point, maybe > we'd like to make exceptions (like we already do for dabbrev-completions > which are bound to a special key rather than to TAB). Good point, given the current mechanism, it's trivial to write a custom completion, with custom list of capfs and bind it to a key. > I used "-capf" within the code of completion-at-point, but I think it's > too cryptic for use outside of that context. Sounds great to me! It's easy to spell, search for and remember, and is more specific than -data. At the end it's just a convention to be used to, and from each function's documentation it will be clear what it means. Thanks, Vitalie.