From unknown Sun Jun 22 22:41:28 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#12456 <12456@debbugs.gnu.org> To: bug#12456 <12456@debbugs.gnu.org> Subject: Status: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Reply-To: bug#12456 <12456@debbugs.gnu.org> Date: Mon, 23 Jun 2025 05:41:28 +0000 retitle 12456 24.2.50; Completion in `Info-goto-node' (cross-manual jump) reassign 12456 emacs submitter 12456 Dani Moncayo severity 12456 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 16 14:01:01 2012 Received: (at submit) by debbugs.gnu.org; 16 Sep 2012 18:01:01 +0000 Received: from localhost ([127.0.0.1]:37513 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDJ9Q-0004mK-Vp for submit@debbugs.gnu.org; Sun, 16 Sep 2012 14:01:01 -0400 Received: from eggs.gnu.org ([208.118.235.92]:37174) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDJ9O-0004mC-Qn for submit@debbugs.gnu.org; Sun, 16 Sep 2012 14:00:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TDJ8F-0006Fe-Nn for submit@debbugs.gnu.org; Sun, 16 Sep 2012 13:59:49 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:55277) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDJ8F-0006FZ-J0 for submit@debbugs.gnu.org; Sun, 16 Sep 2012 13:59:47 -0400 Received: from eggs.gnu.org ([208.118.235.92]:53906) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDJ8E-0000YE-Bs for bug-gnu-emacs@gnu.org; Sun, 16 Sep 2012 13:59:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TDJ8C-0006EW-Nn for bug-gnu-emacs@gnu.org; Sun, 16 Sep 2012 13:59:46 -0400 Received: from mail-ob0-f169.google.com ([209.85.214.169]:58331) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDJ8C-0006E5-Gs for bug-gnu-emacs@gnu.org; Sun, 16 Sep 2012 13:59:44 -0400 Received: by obhx4 with SMTP id x4so8964920obh.0 for ; Sun, 16 Sep 2012 10:59:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=ppRqgBxiiUedykW9MC/1RJ26uDAt97Y1FxhE7aa/pJY=; b=iDv3tMD/2vsTaj0/6q5OZH/KfbDR54sV6WytyEQMBYTlFBk0dLgK0HJdkofW8owBO3 +HszTZU6/xurRJ4hvQTuZVtORtwuxKqXk/6RDRTcxh5erTZi6+3ICSOZGv9vDnMaSp2/ ehZV3WLsvESa9+xWgE8H1jX9BqbQ8PPb9Q5LO01t8ke5jsGdBWRNXvTGAsK59EmkQtRl 5Lkef8JRoI3x8cfD9NJkzHtUO91n5t4zFmbvKmoTk74zYIs/sO3Zm2iE5ImhT7m1GJar sHDZlB1MfmuDVKOO8HtiaxUea8qNel1f3dUTni8fkMPOkoyaCOkzUkYPUA9V8VSCGrob qJkA== MIME-Version: 1.0 Received: by 10.182.109.74 with SMTP id hq10mr9435048obb.56.1347818383484; Sun, 16 Sep 2012 10:59:43 -0700 (PDT) Received: by 10.60.50.130 with HTTP; Sun, 16 Sep 2012 10:59:43 -0700 (PDT) Date: Sun, 16 Sep 2012 19:59:43 +0200 Message-ID: Subject: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) From: Dani Moncayo To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) Recipe from emacs -Q: C-h r g ( e l i s p ) n n When I do it, I see in the echo area the message "[Complete, but not unique]", which is wrong, as the elisp manual has no node called (nor beggining with) "nn". OTOH, if I repeat the experiment but this time with "(elisp)num", Emacs says the same message (this time is right), but a second produces the message "[No completions]", which is wrong, as there is 3 nodes in the elisp manual whose names start with "num". In GNU Emacs 24.2.50.1 (i386-mingw-nt6.1.7601) of 2012-09-16 on DANI-PC Bzr revision: 110047 handa@gnu.org-20120916114848-0p2g6uqosfsrx682 Windowing system distributor `Microsoft Corp.', version 6.1.7601 Configured using: `configure --with-gcc (4.7) --no-opt --enable-checking --cflags -I../../libs/libxpm-3.5.8/include -I../../libs/libxpm-3.5.8/src -I../../libs/libpng-1.4.10 -I../../libs/zlib-1.2.6 -I../../libs/giflib-4.1.4-1/include -I../../libs/jpeg-6b-4/include -I../../libs/tiff-3.8.2-1/include -I../../libs/libxml2-2.7.8-w32-bin/include/libxml2 -I../../libs/gnutls-3.0.16/include -I../../libs/libiconv-1.14-2-mingw32-dev/include' Important settings: value of $LANG: ESN locale-coding-system: cp1252 default enable-multibyte-characters: t -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Sun Sep 16 15:40:36 2012 Received: (at 12456) by debbugs.gnu.org; 16 Sep 2012 19:40:36 +0000 Received: from localhost ([127.0.0.1]:37538 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDKhn-00072G-Jg for submit@debbugs.gnu.org; Sun, 16 Sep 2012 15:40:36 -0400 Received: from mail-ob0-f172.google.com ([209.85.214.172]:52420) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDKhl-000729-H2 for 12456@debbugs.gnu.org; Sun, 16 Sep 2012 15:40:34 -0400 Received: by obbwc20 with SMTP id wc20so8028842obb.3 for <12456@debbugs.gnu.org>; Sun, 16 Sep 2012 12:39:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=4EulaESKRaDd+oD7miBamHNtpuyYHcnOxFKJt0zdG/U=; b=j1V3SEOmiLq+w9B1UUcGBfs8dKsJqz5toB01aDUw8LIFA+U7RueAj6lUSCkIXH22Hw /DXfY39pWmeIfhHg+YUeQoX9qDFN8Vg4SPf2ACmq2CNvJrFfnOmCf6o6kXw0/U4iDj1b QIVn2ZvejyBTrTdNtGeZOaJ0grLS6IAQweHYVxA2Fl94O+cn+V1ksNsS6NPh5VN3gCDy pxvTXorlow2mKD68ZbzlNHyL0a5faIalZJJZNOHivTC/qE5GsUt0yQkMJ98yhPAJVRKR 7xfOAKZWsn0JJhU4Iqai6RVvZNBZBDHmLZKe4hbS11dvPK37ySCjkaewt9jLeSU5XRa1 VbJQ== MIME-Version: 1.0 Received: by 10.60.3.194 with SMTP id e2mr9699222oee.1.1347824362417; Sun, 16 Sep 2012 12:39:22 -0700 (PDT) Received: by 10.60.50.130 with HTTP; Sun, 16 Sep 2012 12:39:22 -0700 (PDT) In-Reply-To: References: Date: Sun, 16 Sep 2012 21:39:22 +0200 Message-ID: Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) From: Dani Moncayo To: 12456@debbugs.gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 12456 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) > Recipe from emacs -Q: C-h r g ( e l i s p ) n n > > When I do it, I see in the echo area the message "[Complete, but not > unique]", which is wrong, as the elisp manual has no node called (nor > beggining with) "nn". > > OTOH, if I repeat the experiment but this time with "(elisp)num", > Emacs says the same message (this time is right), but a second ^^^^^^^^^^^^^^^^^^ Actually this is wrong too, as "(elisp)num" is not _complete_ (besides not being unique). > produces the message "[No completions]", which is wrong, as there is 3 > nodes in the elisp manual whose names start with "num". -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 17 17:13:33 2012 Received: (at 12456) by debbugs.gnu.org; 17 Sep 2012 21:13:33 +0000 Received: from localhost ([127.0.0.1]:40394 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDidJ-00008p-Ch for submit@debbugs.gnu.org; Mon, 17 Sep 2012 17:13:33 -0400 Received: from chene.dit.umontreal.ca ([132.204.246.20]:40533) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDidE-00008a-Ou for 12456@debbugs.gnu.org; Mon, 17 Sep 2012 17:13:32 -0400 Received: from faina.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id q8HLCApI009111; Mon, 17 Sep 2012 17:12:10 -0400 Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id B1E2AB4071; Mon, 17 Sep 2012 17:12:10 -0400 (EDT) From: Stefan Monnier To: Dani Moncayo Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Message-ID: References: Date: Mon, 17 Sep 2012 17:12:10 -0400 In-Reply-To: (Dani Moncayo's message of "Sun, 16 Sep 2012 19:59:43 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.1 (----) > Recipe from emacs -Q: C-h r g ( e l i s p ) n n > When I do it, I see in the echo area the message "[Complete, but not > unique]", which is wrong, as the elisp manual has no node called (nor > beggining with) "nn". > OTOH, if I repeat the experiment but this time with "(elisp)num", > Emacs says the same message (this time is right), but a second > produces the message "[No completions]", which is wrong, as there is 3 > nodes in the elisp manual whose names start with "num". IIRC the core of the problem is that Info's completion table does not (yet) know how to do completion after something like "(elisp)", so it basically returns some "dummy" completion data (because the way completion tables are defined currently, they have no way to say "I don't know"). So there are 2 ways to fix the above problem: - Extend minibuffer.el so a completion table return "don't know" (at which point it could put a message like " [No completion info]"). - Extend info.el so that it does provide actual completion by opening up the "elisp" info file and gathering the corresponding node names. Stefan From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 02:24:34 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 06:24:34 +0000 Received: from localhost ([127.0.0.1]:40715 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDrEY-0002hY-8x for submit@debbugs.gnu.org; Tue, 18 Sep 2012 02:24:34 -0400 Received: from mtaout21.012.net.il ([80.179.55.169]:40786) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDrEU-0002hP-Hl for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 02:24:32 -0400 Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0MAJ00600843ZR00@a-mtaout21.012.net.il> for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 09:23:10 +0300 (IDT) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MAJ006BR8ELYX80@a-mtaout21.012.net.il>; Tue, 18 Sep 2012 09:23:10 +0300 (IDT) Date: Tue, 18 Sep 2012 09:23:18 +0300 From: Eli Zaretskii Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) In-reply-to: X-012-Sender: halo1@inter.net.il To: Stefan Monnier Message-id: <83sjaf26jt.fsf@gnu.org> References: X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, dmoncayo@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Stefan Monnier > Date: Mon, 17 Sep 2012 17:12:10 -0400 > Cc: 12456@debbugs.gnu.org > > > Recipe from emacs -Q: C-h r g ( e l i s p ) n n > > When I do it, I see in the echo area the message "[Complete, but not > > unique]", which is wrong, as the elisp manual has no node called (nor > > beggining with) "nn". > > OTOH, if I repeat the experiment but this time with "(elisp)num", > > Emacs says the same message (this time is right), but a second > > produces the message "[No completions]", which is wrong, as there is 3 > > nodes in the elisp manual whose names start with "num". > > IIRC the core of the problem is that Info's completion table does not > (yet) know how to do completion after something like "(elisp)", so it > basically returns some "dummy" completion data (because the way > completion tables are defined currently, they have no way to say "I > don't know"). Can the completion tables say no completion candidates at all? That would be the best short-term solution; the stand-alone Info reader does just that. > So there are 2 ways to fix the above problem: > - Extend minibuffer.el so a completion table return "don't know" (at > which point it could put a message like " [No completion info]"). > - Extend info.el so that it does provide actual completion by opening up > the "elisp" info file and gathering the corresponding node names. The latter sounds like the best long-term solution to me. Of course, next we will see a bug report with "g (eli TAB"... From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 08:24:11 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 12:24:11 +0000 Received: from localhost ([127.0.0.1]:41079 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDwqY-0003LR-VN for submit@debbugs.gnu.org; Tue, 18 Sep 2012 08:24:11 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:23882) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDwqW-0003LK-TL for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 08:24:09 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ai0FAG6Zu09Ld+qU/2dsb2JhbABEsEiDSYEIghUBAQQBViMFCws0EhQYDSQuh24FugmQRAORQJFzgViDBQ X-IronPort-AV: E=Sophos;i="4.75,637,1330923600"; d="scan'208";a="198587883" Received: from 75-119-234-148.dsl.teksavvy.com (HELO pastel.home) ([75.119.234.148]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 18 Sep 2012 08:22:48 -0400 Received: by pastel.home (Postfix, from userid 20848) id A61A2592A5; Tue, 18 Sep 2012 08:22:47 -0400 (EDT) From: Stefan Monnier To: Eli Zaretskii Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Message-ID: References: <83sjaf26jt.fsf@gnu.org> Date: Tue, 18 Sep 2012 08:22:47 -0400 In-Reply-To: <83sjaf26jt.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 18 Sep 2012 09:23:18 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, dmoncayo@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) >> IIRC the core of the problem is that Info's completion table does not >> (yet) know how to do completion after something like "(elisp)", so it >> basically returns some "dummy" completion data (because the way >> completion tables are defined currently, they have no way to say "I >> don't know"). > Can the completion tables say no completion candidates at all? That > would be the best short-term solution; the stand-alone Info reader > does just that. So that we always get a [No completions] message? We can try. It's all decided in the following three lines of Info-read-node-name-1: ((string-match "\\`(" string) (cond ((eq code nil) string) ((eq code t) nil) (t t))) As long as we don't know the actual list of nodes, it's important to return non-nil when `code' is `lambda': that's the `test-completion' case, which determines whether RET will accept the user's input since the completion is called with `require-match'. >> So there are 2 ways to fix the above problem: >> - Extend minibuffer.el so a completion table return "don't know" (at >> which point it could put a message like " [No completion info]"). >> - Extend info.el so that it does provide actual completion by opening up >> the "elisp" info file and gathering the corresponding node names. > The latter sounds like the best long-term solution to me. Agreed. > Of course, next we will see a bug report with "g (eli TAB"... Try it: that one already works. Stefan From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 09:54:03 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 13:54:03 +0000 Received: from localhost ([127.0.0.1]:41157 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDyFX-0006iS-8f for submit@debbugs.gnu.org; Tue, 18 Sep 2012 09:54:03 -0400 Received: from mtaout22.012.net.il ([80.179.55.172]:52901) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDyFT-0006hs-Ml for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 09:54:01 -0400 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MAJ00H00T56Z300@a-mtaout22.012.net.il> for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 16:52:09 +0300 (IDT) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MAJ00HICT6VU260@a-mtaout22.012.net.il>; Tue, 18 Sep 2012 16:52:07 +0300 (IDT) Date: Tue, 18 Sep 2012 16:52:16 +0300 From: Eli Zaretskii Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) In-reply-to: X-012-Sender: halo1@inter.net.il To: Stefan Monnier Message-id: <83boh31lrj.fsf@gnu.org> References: <83sjaf26jt.fsf@gnu.org> X-Spam-Score: -1.2 (-) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, dmoncayo@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: Eli Zaretskii List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > From: Stefan Monnier > Cc: dmoncayo@gmail.com, 12456@debbugs.gnu.org > Date: Tue, 18 Sep 2012 08:22:47 -0400 > > > Of course, next we will see a bug report with "g (eli TAB"... > > Try it: that one already works. Not if you expect it to show the list of nodes in "(elisp)". From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 10:28:23 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 14:28:23 +0000 Received: from localhost ([127.0.0.1]:41909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDyml-00088p-1H for submit@debbugs.gnu.org; Tue, 18 Sep 2012 10:28:23 -0400 Received: from mail-ee0-f44.google.com ([74.125.83.44]:34734) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TDymi-00088g-U7 for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 10:28:21 -0400 Received: by eekb45 with SMTP id b45so3830804eek.3 for <12456@debbugs.gnu.org>; Tue, 18 Sep 2012 07:27:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=Ax9pAfAlilw8VMAJKbjlZNxoxWy4PQ4Y5SXOzdl/XqA=; b=eUH3zAdM8ogq4yd+CajuiCPpcCZSmJMGFPrhR+193ogN7QSHZfoms1vnHprae1NSq/ 2qk1iCiUa3/FIh+krUbKr6ZxupCJhqt75vPBHAeYs1cufdk4qkE0ez0rpKLQVBQ39LoD /dE0NLvz4RJ5ShSeaQLaOFQldcIR9SKNnGjQXCFG/ABlsVUY4bk1Mt9H3jIT56EXTo5O krsit4viaefgkhlSDVcuEhAVdausCYdHC/XQSVPyjt51vLJoRw+eOAhDtx1X9Wmvxaqw vBoZwTxxB0UcuoEcuMe4LyBnEZHqb0v7Sq8Xzgi7NrUI3GoCwiKo3XnEg2MxqZ3vRFit 0H+A== MIME-Version: 1.0 Received: by 10.14.182.134 with SMTP id o6mr19716eem.26.1347978419948; Tue, 18 Sep 2012 07:26:59 -0700 (PDT) Received: by 10.14.203.135 with HTTP; Tue, 18 Sep 2012 07:26:59 -0700 (PDT) In-Reply-To: <83boh31lrj.fsf@gnu.org> References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> Date: Tue, 18 Sep 2012 16:26:59 +0200 Message-ID: Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) From: Dani Moncayo To: Eli Zaretskii Content-Type: text/plain; charset=ISO-8859-1 X-Spam-Score: -2.6 (--) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, Stefan Monnier X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) >> > Of course, next we will see a bug report with "g (eli TAB"... >> >> Try it: that one already works. > > Not if you expect it to show the list of nodes in "(elisp)". I think that a reasonable behavior would be: * "(eli" completes just to "(elisp)" (or all manuals which begin with "eli"). * "(elisp)" completes to all nodes in the elisp manual. -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 12:58:50 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 16:58:50 +0000 Received: from localhost ([127.0.0.1]:42063 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TE18L-0007Y2-JH for submit@debbugs.gnu.org; Tue, 18 Sep 2012 12:58:50 -0400 Received: from pruche.dit.umontreal.ca ([132.204.246.22]:36500) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TE18H-0007Xi-Hf for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 12:58:48 -0400 Received: from faina.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id q8IGvMtl026595; Tue, 18 Sep 2012 12:57:23 -0400 Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id ACCD8B4071; Tue, 18 Sep 2012 12:57:22 -0400 (EDT) From: Stefan Monnier To: Dani Moncayo Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Message-ID: References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> Date: Tue, 18 Sep 2012 12:57:22 -0400 In-Reply-To: (Dani Moncayo's message of "Tue, 18 Sep 2012 16:26:59 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -4.1 (----) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, Eli Zaretskii X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -4.1 (----) > I think that a reasonable behavior would be: > * "(eli" completes just to "(elisp)" (or all manuals which begin > with "eli"). Yes, that already works. > * "(elisp)" completes to all nodes in the elisp manual. Yes, that's the part that's not yet implemented. Patch welcome, Stefan From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 18 16:09:48 2012 Received: (at 12456) by debbugs.gnu.org; 18 Sep 2012 20:09:48 +0000 Received: from localhost ([127.0.0.1]:42271 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TE47A-0000r5-A6 for submit@debbugs.gnu.org; Tue, 18 Sep 2012 16:09:48 -0400 Received: from ps18281.dreamhost.com ([69.163.218.105]:59320 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TE477-0000qw-Fq for 12456@debbugs.gnu.org; Tue, 18 Sep 2012 16:09:46 -0400 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id D8BC6451CC45; Tue, 18 Sep 2012 13:08:21 -0700 (PDT) From: Juri Linkov To: Stefan Monnier Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> Date: Tue, 18 Sep 2012 23:03:21 +0300 In-Reply-To: (Stefan Monnier's message of "Tue, 18 Sep 2012 12:57:22 -0400") Message-ID: <87a9wn85fa.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, Dani Moncayo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) >> * "(elisp)" completes to all nodes in the elisp manual. > > Yes, that's the part that's not yet implemented. Patch welcome, This can be implemented by this patch. The remaining problem is that it's too slow because it doesn't cache completions of non-current manuals. Perhaps `Info-build-node-completions' should use `Info-toc-nodes' that caches node names from all visited manuals. === modified file 'lisp/info.el' --- lisp/info.el 2012-09-13 22:01:45 +0000 +++ lisp/info.el 2012-09-18 20:02:43 +0000 @@ -1778,12 +1778,23 @@ (defun Info-read-node-name-1 (string pre (substring string 1) predicate code)) - ;; If a file name was given, then any node is fair game. - ((string-match "\\`(" string) - (cond - ((eq code nil) string) - ((eq code t) nil) - (t t))) + ;; If a file name was given, complete nodes in the file. + ((string-match "\\`([^)]+)" string) + (let ((file (match-string 0 string)) + (node (substring string (match-end 0)))) + (completion-table-with-context + file + (apply-partially + (lambda (string pred action) + (complete-with-action + action + (with-temp-buffer + (Info-mode) + (Info-goto-node (concat file "Top")) + (Info-build-node-completions) + Info-current-file-completions) + string pred))) + node predicate code))) ;; Otherwise use Info-read-node-completion-table. (t (complete-with-action code Info-read-node-completion-table string predicate)))) From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 15 10:36:51 2012 Received: (at 12456) by debbugs.gnu.org; 15 Dec 2012 15:36:51 +0000 Received: from localhost ([127.0.0.1]:44214 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TjtnG-0007tz-9f for submit@debbugs.gnu.org; Sat, 15 Dec 2012 10:36:51 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:57172 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tjtn7-0007ta-Bx for 12456@debbugs.gnu.org; Sat, 15 Dec 2012 10:36:44 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id C5298451CD60; Sat, 15 Dec 2012 07:35:35 -0800 (PST) From: Juri Linkov To: Stefan Monnier Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> Date: Sat, 15 Dec 2012 17:30:30 +0200 In-Reply-To: <87a9wn85fa.fsf@mail.jurta.org> (Juri Linkov's message of "Tue, 18 Sep 2012 23:03:21 +0300") Message-ID: <87mwxfl4dl.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org, Dani Moncayo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) >>> * "(elisp)" completes to all nodes in the elisp manual. >> >> Yes, that's the part that's not yet implemented. Patch welcome, > > This can be implemented by this patch. The remaining problem is > that it's too slow because it doesn't cache completions of non-current > manuals. Perhaps `Info-build-node-completions' should use `Info-toc-nodes' > that caches node names from all visited manuals. Actually I realized that `Info-toc-nodes' can't be used because it doesn't contain Info anchors whereas `Info-build-node-completions' adds anchors along with references. So to be able to cache completions in non-current manuals requires adding a global variable `Info-file-completions' like in the patch below: === modified file 'lisp/info.el' --- lisp/info.el 2012-12-08 23:12:08 +0000 +++ lisp/info.el 2012-12-15 15:28:17 +0000 @@ -397,6 +395,10 @@ (defvar Info-tag-table-buffer nil (defvar Info-current-file-completions nil "Cached completion list for current Info file.") +(defvar Info-file-completions nil + "Cached completion alist of visited Info files. +Each element of the alist is (FILE . COMPLETIONS)") + (defvar Info-file-supports-index-cookies nil "Non-nil if current Info file supports index cookies.") @@ -1771,12 +1783,20 @@ (defun Info-read-node-name-1 (string pre (substring string 1) predicate code)) - ;; If a file name was given, then any node is fair game. - ((string-match "\\`(" string) - (cond - ((eq code nil) string) - ((eq code t) nil) - (t t))) + ;; If a file name was given, complete nodes in the file. + ((string-match "\\`(\\([^)]+\\))" string) + (let ((file0 (match-string 0 string)) + (file1 (match-string 1 string)) + (node (substring string (match-end 0)))) + (completion-table-with-context + file0 + (apply-partially + (lambda (string pred action) + (complete-with-action + action + (Info-build-node-completions (Info-find-file file1)) + string pred))) + node predicate code))) ;; Otherwise use Info-read-node-completion-table. (t (complete-with-action code Info-read-node-completion-table string predicate)))) @@ -1793,8 +1813,19 @@ (defun Info-read-node-name (prompt) (Info-read-node-name prompt) nodename))) -(defun Info-build-node-completions () +(defun Info-build-node-completions (&optional file) + (if file + (or (cdr (assoc file Info-file-completions)) + (with-temp-buffer + (Info-mode) + (Info-goto-node (format "(%s)Top" file)) + (Info-build-node-completions-1) + (push (cons file Info-current-file-completions) Info-file-completions) + Info-file-completions)) (or Info-current-file-completions + (Info-build-node-completions-1)))) + +(defun Info-build-node-completions-1 () (let ((compl nil) ;; Bind this in case the user sets it to nil. (case-fold-search t) @@ -1826,8 +1857,10 @@ (defun Info-build-node-completions () (setq compl (cons (list (match-string-no-properties 1)) compl)))))))) - (setq compl (cons '("*") compl)) - (set (make-local-variable 'Info-current-file-completions) compl)))) + (setq compl (cons '("*") (nreverse compl))) + (set (make-local-variable 'Info-current-file-completions) compl) + compl)) + (defun Info-restore-point (hl) "If this node has been visited, restore the point value when we left." From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 27 15:44:00 2012 Received: (at 12456-done) by debbugs.gnu.org; 27 Dec 2012 20:44:00 +0000 Received: from localhost ([127.0.0.1]:34053 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToKJ5-0007lA-Ei for submit@debbugs.gnu.org; Thu, 27 Dec 2012 15:44:00 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:44670 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToKJ2-0007l2-Pe for 12456-done@debbugs.gnu.org; Thu, 27 Dec 2012 15:43:57 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id A27A3451C308 for <12456-done@debbugs.gnu.org>; Thu, 27 Dec 2012 12:43:06 -0800 (PST) From: Juri Linkov To: 12456-done@debbugs.gnu.org Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> Date: Thu, 27 Dec 2012 22:42:18 +0200 In-Reply-To: <87mwxfl4dl.fsf@mail.jurta.org> (Juri Linkov's message of "Sat, 15 Dec 2012 17:30:30 +0200") Message-ID: <87k3s3grbp.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 12456-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -0.0 (/) > So to be able to cache completions in non-current manuals > requires adding a global variable `Info-file-completions' > like in the patch below: Installed to the trunk and closed. From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 27 16:38:00 2012 Received: (at 12456) by debbugs.gnu.org; 27 Dec 2012 21:38:00 +0000 Received: from localhost ([127.0.0.1]:34088 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToL9L-0000em-OP for submit@debbugs.gnu.org; Thu, 27 Dec 2012 16:37:59 -0500 Received: from mail-ob0-f173.google.com ([209.85.214.173]:39496) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToL9G-0000dy-Ox for 12456@debbugs.gnu.org; Thu, 27 Dec 2012 16:37:57 -0500 Received: by mail-ob0-f173.google.com with SMTP id xn12so9279402obc.32 for <12456@debbugs.gnu.org>; Thu, 27 Dec 2012 13:37:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=K+z9PNDD5+qEHTNPlGUooxGud4glg1SGAcGpvWV5Bds=; b=pnZvVhC4gXK/u+9KQHBXj62WHNKdrBLj8cl470hB0IBXeB2MAVi0jHUexgIjVLQjEU W7YuEdWUKnM2+E1icu+Hx3BMy1boMojVaYWnnIRn9WJlXowcPtJVoEnHxM1xa83vihYP lyeeM306zrAXghwfcGszcz93tPVtpTEdMR4uz4YYGkM9yRSWy+rjOzfMUq/bRgGr34KX VSqVsCXqZcKZhvzYS0GBC48N1nn00WUSFjakvymbyYMCuBdspViHoz9XpiUQK7pRSrfU ZotUsivSRK8SkWZKQw0X44fZ5ZjCAdgCb1vvHBsImfokHmFX//+QqjDPFXv6CJuAhKdh 00oQ== MIME-Version: 1.0 Received: by 10.182.144.7 with SMTP id si7mr17145684obb.94.1356644224316; Thu, 27 Dec 2012 13:37:04 -0800 (PST) Received: by 10.60.11.39 with HTTP; Thu, 27 Dec 2012 13:37:04 -0800 (PST) In-Reply-To: <87k3s3grbp.fsf@mail.jurta.org> References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> Date: Thu, 27 Dec 2012 22:37:04 +0100 Message-ID: Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) From: Dani Moncayo To: juri@jurta.org Content-Type: text/plain; charset=ISO-8859-1 X-Spam-Score: 1.8 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> So to be able to cache completions in non-current manuals >> requires adding a global variable `Info-file-completions' >> like in the patch below: > > Installed to the trunk and closed. Thanks, Juri. [...] Content analysis details: (1.8 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.214.173 listed in list.dnswl.org] 1.7 URIBL_BLACK Contains an URL listed in the URIBL blacklist [URIs: elisp.info] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (dmoncayo[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] 0.0 T_DKIM_INVALID DKIM-Signature header exists but is not valid X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 1.8 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: >> So to be able to cache completions in non-current manuals >> requires adding a global variable `Info-file-completions' >> like in the patch below: > > Installed to the trunk and closed. Thanks, Juri. [...] Content analysis details: (1.8 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.214.173 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (dmoncayo[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 1.7 URIBL_BLACK Contains an URL listed in the URIBL blacklist [URIs: elisp.info] 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4791] 0.0 T_DKIM_INVALID DKIM-Signature header exists but is not valid >> So to be able to cache completions in non-current manuals >> requires adding a global variable `Info-file-completions' >> like in the patch below: > > Installed to the trunk and closed. Thanks, Juri. One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see two completion candidates: "elisp" and "elisp.info". This is a bug, no? -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 27 17:23:54 2012 Received: (at 12456) by debbugs.gnu.org; 27 Dec 2012 22:23:54 +0000 Received: from localhost ([127.0.0.1]:34149 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToLrl-0001pW-KL for submit@debbugs.gnu.org; Thu, 27 Dec 2012 17:23:53 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:39125 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1ToLri-0001pH-JE for 12456@debbugs.gnu.org; Thu, 27 Dec 2012 17:23:52 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 9243E451C308; Thu, 27 Dec 2012 14:22:59 -0800 (PST) From: Juri Linkov To: Dani Moncayo Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> Date: Thu, 27 Dec 2012 23:57:04 +0200 In-Reply-To: (Dani Moncayo's message of "Thu, 27 Dec 2012 22:37:04 +0100") Message-ID: <87bodfgntf.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 2.5 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see > two completion candidates: "elisp" and "elisp.info". This is a bug, > no? I doubt its usefulness too because it doesn't allow TAB to add the closing paren automatically as it does for a single completion, but as a comment in `Info-read-node-name-2' says: [...] Content analysis details: (2.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.7 URIBL_BLACK Contains an URL listed in the URIBL blacklist [URIs: elisp.info] 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.5000] X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: 2.5 (++) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: > One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see > two completion candidates: "elisp" and "elisp.info". This is a bug, > no? I doubt its usefulness too because it doesn't allow TAB to add the closing paren automatically as it does for a single completion, but as a comment in `Info-read-node-name-2' says: [...] Content analysis details: (2.5 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.7 URIBL_BLACK Contains an URL listed in the URIBL blacklist [URIs: elisp.info] 0.8 BAYES_50 BODY: Bayes spam probability is 40 to 60% [score: 0.4960] > One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see > two completion candidates: "elisp" and "elisp.info". This is a bug, > no? I doubt its usefulness too because it doesn't allow TAB to add the closing paren automatically as it does for a single completion, but as a comment in `Info-read-node-name-2' says: ;; If the file name ends in a standard suffix, ;; add the unsuffixed name as a completion option. So code adds both "elisp.info" with a standard suffix ".info" and the unsuffixed name "elisp". This means this intentionally is a feature, and not a bug. From debbugs-submit-bounces@debbugs.gnu.org Fri Dec 28 19:19:40 2012 Received: (at 12456) by debbugs.gnu.org; 29 Dec 2012 00:19:40 +0000 Received: from localhost ([127.0.0.1]:35372 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tok9L-0001mw-SY for submit@debbugs.gnu.org; Fri, 28 Dec 2012 19:19:40 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:56573 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tok9I-0001mi-4o for 12456@debbugs.gnu.org; Fri, 28 Dec 2012 19:19:38 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 3DFC0451C551; Fri, 28 Dec 2012 16:18:38 -0800 (PST) From: Juri Linkov To: Dani Moncayo Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> <87bodfgntf.fsf@mail.jurta.org> Date: Sat, 29 Dec 2012 01:57:11 +0200 In-Reply-To: <87bodfgntf.fsf@mail.jurta.org> (Juri Linkov's message of "Thu, 27 Dec 2012 23:57:04 +0200") Message-ID: <87han51zx8.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -0.0 (/) >> One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see >> two completion candidates: "elisp" and "elisp.info". This is a bug, >> no? > > I doubt its usefulness too because it doesn't allow TAB to add the > closing paren automatically as it does for a single completion, > but as a comment in `Info-read-node-name-2' says: > > ;; If the file name ends in a standard suffix, > ;; add the unsuffixed name as a completion option. > > So code adds both "elisp.info" with a standard suffix ".info" > and the unsuffixed name "elisp". > > This means this intentionally is a feature, and not a bug. But this doesn't mean it is a good feature. Another similar command `info-display-manual' doesn't add duplicates "elisp" and "elisp.info", so when you do `M-x info-display-manual RET TAB' it displays a single completion for every Info manual name without adding the suffix ".info". From debbugs-submit-bounces@debbugs.gnu.org Fri Dec 28 19:25:35 2012 Received: (at 12456) by debbugs.gnu.org; 29 Dec 2012 00:25:36 +0000 Received: from localhost ([127.0.0.1]:35377 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TokF5-0001wH-K3 for submit@debbugs.gnu.org; Fri, 28 Dec 2012 19:25:35 -0500 Received: from mail-ob0-f178.google.com ([209.85.214.178]:61368) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TokF3-0001w7-0d for 12456@debbugs.gnu.org; Fri, 28 Dec 2012 19:25:34 -0500 Received: by mail-ob0-f178.google.com with SMTP id eh20so9949467obb.23 for <12456@debbugs.gnu.org>; Fri, 28 Dec 2012 16:24:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=HvfLobKXU5caCtYOLM4bM3PzunPTGNiS3zIUlJlKBfE=; b=IVcYLgi5dTHcaPihaxwqZwZP0WVXd9BdjcfGfgczVR1U7je9fSkBX9TJ3FnuZ/tt2W eoOqmIDiiXDHlag8LvcI6CUKR2ZyfhW4QtoePcT27LFpnkEoGZsMxxQRLQN8U5paX3jB yEr5ofymmuVgQOGpaGDnu3c4BVnXSh0AMhvvA/rkJhE6f7giS9x/akw211DlNJKk1XfY Kb0zHsH7rY6H5iz7wi2Z0Exs6NrG/l44Es7pIkHbPsfGJt2ezq6v95I0cn1DFeVIlMzv 82LLraNKAV2uUZDYR/oJEu0LOMyERySHiwwQyu6KOiALe7zorOyyTDCn7NjqWkzBANkh Ab7A== MIME-Version: 1.0 Received: by 10.60.172.143 with SMTP id bc15mr16816850oec.46.1356740675598; Fri, 28 Dec 2012 16:24:35 -0800 (PST) Received: by 10.60.11.39 with HTTP; Fri, 28 Dec 2012 16:24:35 -0800 (PST) In-Reply-To: <87han51zx8.fsf@mail.jurta.org> References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> <87bodfgntf.fsf@mail.jurta.org> <87han51zx8.fsf@mail.jurta.org> Date: Sat, 29 Dec 2012 01:24:35 +0100 Message-ID: Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) From: Dani Moncayo To: Juri Linkov Content-Type: text/plain; charset=ISO-8859-1 X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -0.7 (/) >>> One question: if I do (from emacs -Q) `C-h r g ( e l i TAB TAB', I see >>> two completion candidates: "elisp" and "elisp.info". This is a bug, >>> no? >> >> I doubt its usefulness too because it doesn't allow TAB to add the >> closing paren automatically as it does for a single completion, >> but as a comment in `Info-read-node-name-2' says: >> >> ;; If the file name ends in a standard suffix, >> ;; add the unsuffixed name as a completion option. >> >> So code adds both "elisp.info" with a standard suffix ".info" >> and the unsuffixed name "elisp". >> >> This means this intentionally is a feature, and not a bug. > > But this doesn't mean it is a good feature. Another similar command > `info-display-manual' doesn't add duplicates "elisp" and "elisp.info", > so when you do `M-x info-display-manual RET TAB' it displays a single > completion for every Info manual name without adding the suffix ".info". Yes, I don't see the point of duplicating each available info manual. So I consider that a bug, and I'd be glad if it was fixed. -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 29 17:21:13 2012 Received: (at 12456) by debbugs.gnu.org; 29 Dec 2012 22:21:13 +0000 Received: from localhost ([127.0.0.1]:36428 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tp4mG-000357-FY for submit@debbugs.gnu.org; Sat, 29 Dec 2012 17:21:13 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:48656 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Tp4m3-00034O-6v for 12456@debbugs.gnu.org; Sat, 29 Dec 2012 17:21:01 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 64B8C451CE1E; Sat, 29 Dec 2012 14:19:57 -0800 (PST) From: Juri Linkov To: Dani Moncayo Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> <87bodfgntf.fsf@mail.jurta.org> <87han51zx8.fsf@mail.jurta.org> Date: Sat, 29 Dec 2012 23:59:47 +0200 In-Reply-To: (Dani Moncayo's message of "Sat, 29 Dec 2012 01:24:35 +0100") Message-ID: <87vcbkzf9d.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: 12456 Cc: 12456@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) > Yes, I don't see the point of duplicating each available info manual. > So I consider that a bug, and I'd be glad if it was fixed. Duplicating each available info manual might be useful for something since it is intentionally implemented this way, but at least we could fix the case like `g ( e l i TAB' where there is just one completion candidate, so TAB will complete it without suffix and add the closing paren. Also this patch fixes another problem with `Info-read-node-name-2' in `info-display-manual' where I noticed that `M-x info-display-manual RET TAB' displays a completion list like Possible completions are: &rest apply closure elisp when there are opened Info manuals. This problem is caused by appending a list of opened manual names to a closure. To fix this, a closure could be expanded to the list of available manual names with (all-completions "" (apply-partially ...) Another problem is that if an Info manual is opened in a temporary buffer with the leading space in the buffer name, it should skip such buffers with (not (string= (substring (buffer-name) 0 1) " ")) === modified file 'lisp/info.el' --- lisp/info.el 2012-12-28 22:07:07 +0000 +++ lisp/info.el 2012-12-29 21:59:36 +0000 @@ -1744,6 +1744,7 @@ (defun Info-read-node-name-2 (dirs suffi (when (file-name-absolute-p string) (setq dirs (list (file-name-directory string)))) (let ((names nil) + (names-sans-suffix nil) (suffix (concat (regexp-opt suffixes t) "\\'")) (string-dir (file-name-directory string))) (dolist (dir dirs) @@ -1766,7 +1767,14 @@ (defun Info-read-node-name-2 (dirs suffi ;; add the unsuffixed name as a completion option. (when (string-match suffix file) (setq file (substring file 0 (match-beginning 0))) - (push (if string-dir (concat string-dir file) file) names))))) + (push (if string-dir (concat string-dir file) file) + names-sans-suffix))))) + ;; If there is just one file, don't duplicate it with suffixes, + ;; so `Info-read-node-name-1' will be able to complete a single + ;; candidate and to add the terminating ")". + (if (and (= (length names) 1) (= (length names-sans-suffix) 1)) + (setq names names-sans-suffix) + (setq names (append names-sans-suffix names))) (complete-with-action action names string pred))) (defun Info-read-node-name-1 (string predicate code) @@ -5181,13 +5189,16 @@ (defun info--manual-names () (with-current-buffer buffer (and (eq major-mode 'Info-mode) (stringp Info-current-file) + (not (string= (substring (buffer-name) 0 1) " ")) (push (file-name-sans-extension (file-name-nondirectory Info-current-file)) names)))) (delete-dups (append (nreverse names) - (apply-partially 'Info-read-node-name-2 - Info-directory-list - (mapcar 'car Info-suffix-list)))))) + (all-completions + "" + (apply-partially 'Info-read-node-name-2 + Info-directory-list + (mapcar 'car Info-suffix-list))))))) (provide 'info) From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 07 19:32:26 2013 Received: (at control) by debbugs.gnu.org; 8 Jan 2013 00:32:26 +0000 Received: from localhost ([127.0.0.1]:55785 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TsN7B-0006oP-G2 for submit@debbugs.gnu.org; Mon, 07 Jan 2013 19:32:26 -0500 Received: from ps18281.dreamhost.com ([69.163.218.105]:45840 helo=ps18281.dreamhostps.com) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TsN78-0006oH-R0 for control@debbugs.gnu.org; Mon, 07 Jan 2013 19:32:23 -0500 Received: from localhost (ps18281.dreamhostps.com [69.163.218.105]) by ps18281.dreamhostps.com (Postfix) with ESMTP id 84D5E2017CE800 for ; Mon, 7 Jan 2013 16:32:20 -0800 (PST) From: Juri Linkov To: control@debbugs.gnu.org Subject: Re: bug#12456: 24.2.50; Completion in `Info-goto-node' (cross-manual jump) Organization: JURTA References: <83sjaf26jt.fsf@gnu.org> <83boh31lrj.fsf@gnu.org> <87a9wn85fa.fsf@mail.jurta.org> <87mwxfl4dl.fsf@mail.jurta.org> <87k3s3grbp.fsf@mail.jurta.org> <87bodfgntf.fsf@mail.jurta.org> <87han51zx8.fsf@mail.jurta.org> <87vcbkzf9d.fsf@mail.jurta.org> Date: Tue, 08 Jan 2013 02:31:49 +0200 In-Reply-To: <87vcbkzf9d.fsf@mail.jurta.org> (Juri Linkov's message of "Sat, 29 Dec 2012 23:59:47 +0200") Message-ID: <87fw2cecqy.fsf@mail.jurta.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.8 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -0.0 (/) fixed 12456 24.3.50 stop From unknown Sun Jun 22 22:41:28 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 05 Feb 2013 12:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator