From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Add user customization fido-completion-styles Date: Tue, 02 Jun 2020 21:35:18 +0300 Message-ID: <83h7vtco49.fsf@gnu.org> References: <87r1uzn018.fsf@gmail.com> <953E1512-6420-4AE8-AF29-15AB151B6344@schwartzmeyer.com> <877dwpn2id.fsf@gmail.com> <3483a8d9-1474-45cf-afad-8d276b96ef3f@default> <87sgfdl5jw.fsf@gmail.com> <83img9cp7j.fsf@gnu.org> <87o8q1l40i.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="17231"; mail-complaints-to="usenet@ciao.gmane.io" Cc: drew.adams@oracle.com, emacs-devel@gnu.org To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jun 02 20:37:45 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jgBnF-0004Pg-I9 for ged-emacs-devel@m.gmane-mx.org; Tue, 02 Jun 2020 20:37:45 +0200 Original-Received: from localhost ([::1]:59886 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jgBnE-0002Dq-LF for ged-emacs-devel@m.gmane-mx.org; Tue, 02 Jun 2020 14:37:44 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54470) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jgBlA-0008EF-TJ for emacs-devel@gnu.org; Tue, 02 Jun 2020 14:35:36 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:50770) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jgBlA-0003N4-Aj; Tue, 02 Jun 2020 14:35:36 -0400 Original-Received: from [176.228.60.248] (port=1299 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1jgBl9-0000h5-H2; Tue, 02 Jun 2020 14:35:36 -0400 In-Reply-To: <87o8q1l40i.fsf@gmail.com> (message from =?utf-8?B?Sm/Do28g?= =?utf-8?B?VMOhdm9yYQ==?= on Tue, 02 Jun 2020 19:24:45 +0100) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:251777 Archived-At: > From: João Távora > Cc: drew.adams@oracle.com, emacs-devel@gnu.org > Date: Tue, 02 Jun 2020 19:24:45 +0100 > > This is complete-with-action minus docstring, can you help me understand > what's going on? > > (defun complete-with-action (action collection string predicate) > (cond > ((functionp collection) (funcall collection string predicate action)) > ((eq (car-safe action) 'boundaries) nil) > ((eq action 'metadata) nil) > (t > (funcall > (cond > ((null action) 'try-completion) > ((eq action t) 'all-completions) > (t 'test-completion)) > string collection predicate)))) What is 'collection'? is it a function? Anyway, I suggest to run the same experiment after loading all the code involved in this as *.el files (not *.elc). That should show a more detailed profile, which hopefully will give a clue.