From unknown Sat Sep 06 09:27:49 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#12564 <12564@debbugs.gnu.org> To: bug#12564 <12564@debbugs.gnu.org> Subject: Status: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph Reply-To: bug#12564 <12564@debbugs.gnu.org> Date: Sat, 06 Sep 2025 16:27:49 +0000 retitle 12564 24.1; Emacs Lisp Reference Manual; Confusing paragraph regard= ing association lists' definition; Section 20.6.1 "Basic Completion Functio= ns"; 5th paragraph reassign 12564 emacs submitter 12564 oitofelix@gmail.com (Bruno F=C3=A9lix Rezende Ribeiro) severity 12564 minor thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Oct 02 15:42:08 2012 Received: (at submit) by debbugs.gnu.org; 2 Oct 2012 19:42:08 +0000 Received: from localhost ([127.0.0.1]:38095 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJ8M3-0006rD-W2 for submit@debbugs.gnu.org; Tue, 02 Oct 2012 15:42:08 -0400 Received: from eggs.gnu.org ([208.118.235.92]:36727) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJ8M2-0006r6-6e for submit@debbugs.gnu.org; Tue, 02 Oct 2012 15:42:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TJ8LT-0000s6-GD for submit@debbugs.gnu.org; Tue, 02 Oct 2012 15:41:32 -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]:47639) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJ8LT-0000s2-DM for submit@debbugs.gnu.org; Tue, 02 Oct 2012 15:41:31 -0400 Received: from eggs.gnu.org ([208.118.235.92]:56403) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJ8LP-0003jn-9a for bug-gnu-emacs@gnu.org; Tue, 02 Oct 2012 15:41:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TJ8LK-0000qn-Ti for bug-gnu-emacs@gnu.org; Tue, 02 Oct 2012 15:41:27 -0400 Received: from mail-gg0-f169.google.com ([209.85.161.169]:38268) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJ8LK-0000qj-PN for bug-gnu-emacs@gnu.org; Tue, 02 Oct 2012 15:41:22 -0400 Received: by ggnf4 with SMTP id f4so1835094ggn.0 for ; Tue, 02 Oct 2012 12:41:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id:user-agent:mime-version :content-type:content-transfer-encoding; bh=FiZ3ea1C5tQ7PVMlT+tkXAv0zxHuRub5RWuNNYrj0IM=; b=CXWCQHTlAGhgDw+1Wandd9FCMFaXSpPns+xydzFwXN92Bflb+2r9ee/KIa1MHRC1bU yHVM/CKz9JG6tSmyJ3TfNnO2pH8lYZaRs4LdEWekZ88tkQHHgyfbXVfPXErPXiVM73iV SFzk2OWzie+d2cGYlV17ZES4uePgReAet3bJ/U//09IFXs9weuUccbikaw6zc3nkyrmE 1IuuaRAw32ba0SvEBL2Ih1Dv7Vc3pp1yCkhKwxdL1+adPgGDOAjop8Gzz9pMAyMsX3gm jA2yJqJLOeWF0my0tRokKCJN/VKZ8RbYzU+Kgrw2slsbDhfNObdndKtF4T4WIbMzyRKw r/NA== Received: by 10.100.172.2 with SMTP id u2mr6007599ane.17.1349206882380; Tue, 02 Oct 2012 12:41:22 -0700 (PDT) Received: from felix-laptop ([177.30.232.206]) by mx.google.com with ESMTPS id f15sm1930287anm.9.2012.10.02.12.41.19 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 02 Oct 2012 12:41:21 -0700 (PDT) From: oitofelix@gmail.com (Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro) To: bug-gnu-emacs@gnu.org Subject: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph Date: Tue, 02 Oct 2012 16:44:21 -0300 Message-ID: <87pq508xre.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: -3.4 (---) 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: -3.4 (---) This bug report will be sent to the Bug-GNU-Emacs mailing list and the GNU bug tracker at debbugs.gnu.org. Please check that the From: line contains a valid email address. After a delay of up to one day, you should receive an acknowledgement at that address. Please write in English if possible, as the Emacs maintainers usually do not have translators for other languages. Please describe exactly what actions triggered the bug, and the precise symptoms of the bug. If you can, give a recipe starting from `emacs -Q': In GNU Emacs Lisp Reference Manual, section 20.6.1, entitled "Basic Completion Functions", in the 5th paragraph one can read: If COLLECTION is an alist (*note Association Lists::), the permissible completions are the elements of the alist that are either strings, or conses whose CAR is a string or symbol. Symbols are converted to strings using `symbol-name'. Other elements of the alist are ignored. (Remember that in Emacs Lisp, the elements of alists do not _have_ to be conses.) In particular, a list of strings is allowed, even though we usually do not think of such lists as alists. The key affirmation is "... in Emacs Lisp, the elements of alists do not _have_ to be conses". In the paragraph's first sentence there is a reference to section 5.8 "Association Lists" in the same manual, where one can read in the first paragraph: An "association list", or "alist" for short, records a mapping from keys to values. It is a list of cons cells called "associations": the CAR of each cons cell is the "key", and the CDR is the "associated value".(1) The key affirmation here is "... It is [association lists] a list of cons cells ...". Hence, we conclude an association list is a list of cons cells that doesn't need to be cons cells. If we assume the manual is consistent, we only can infer, supposing a language abuse, the following: An association list is any sort of list. or, perhaps more appropriate, An association list is any list that has none elements or at least one cons cell and possibly other elements. Since I don't know what is the case, either I'm missing something trivial, = or that is a manual bug. Even if it's consistent, I think it could be more clear. Thanks. In GNU Emacs 24.1.1 (i686-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-08-26 on felix-laptop Windowing system distributor `The X.Org Foundation', version 11.0.10903000 Configured using: `configure 'CFLAGS=3D-pipe -O3 -march=3Datom -mtune=3Datom -mmmx -msse -ms= se2 -msse3 -mssse3 -mfpmath=3Dsse'' --=20 ,=3D ,-_-. =3D. Bruno F=C3=A9lix Rezende Ribeiro (oitofelix) ((_/)o o(\_)) Uns o chamam de super-vaca... `-'(. .)`-' Outros de hiper-touro... \_/ Eu o chamo simplesmente: meta-gnu! From debbugs-submit-bounces@debbugs.gnu.org Tue Oct 02 16:28:40 2012 Received: (at 12564) by debbugs.gnu.org; 2 Oct 2012 20:28:40 +0000 Received: from localhost ([127.0.0.1]:38126 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJ955-0000KK-Na for submit@debbugs.gnu.org; Tue, 02 Oct 2012 16:28:39 -0400 Received: from rcsinet15.oracle.com ([148.87.113.117]:51850) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJ953-0000KB-A9 for 12564@debbugs.gnu.org; Tue, 02 Oct 2012 16:28:38 -0400 Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by rcsinet15.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id q92KS1lq000809 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 2 Oct 2012 20:28:02 GMT Received: from acsmt358.oracle.com (acsmt358.oracle.com [141.146.40.158]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id q92KS1dZ000211 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 2 Oct 2012 20:28:01 GMT Received: from abhmt105.oracle.com (abhmt105.oracle.com [141.146.116.57]) by acsmt358.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id q92KS1NE025251; Tue, 2 Oct 2012 15:28:01 -0500 Received: from dradamslap1 (/130.35.178.248) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 02 Oct 2012 13:28:01 -0700 From: "Drew Adams" To: "=?iso-8859-1?Q?'Bruno_=22F=E9lix=22_Rezende_Ribeiro'?=" , <12564@debbugs.gnu.org> References: <87pq508xre.fsf@gmail.com> Subject: RE: bug#12564: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph Date: Tue, 2 Oct 2012 13:27:59 -0700 Message-ID: <9C99AC9C311D44DE8BF1FF1C75F80A24@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <87pq508xre.fsf@gmail.com> Thread-Index: Ac2g1hM//qwj5ipGRuq0fKQFR/NJLgABZSSw X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: acsinet21.oracle.com [141.146.126.237] X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: 12564 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.3 (------) > In the paragraph's first sentence there is a reference to section 5.8 > "Association Lists" in the same manual, where one can read in > the first paragraph: > > An "association list", or "alist" for short, records a mapping from > keys to values. It is a list of cons cells called > "associations": the CAR of each cons cell is the "key", and the > CDR is the "associated value".(1) And where one can read the following qualification, in the eighth paragraph: In Emacs Lisp, it is _not_ an error if an element of an association list is not a cons cell. The alist search functions simply ignore such elements. Many other versions of Lisp signal errors in such cases. You have to read beyon the intro at the beginning, to get to the details. The intro gives the basic idea and an illustrative example. The corner case (ignoring a non-cons element vs raising an error) is mentioned later. And that's the right presentation order, IMHO. > An association list is any list that has none elements or at least one > cons cell and possibly other elements. > > Since I don't know what is the case, either I'm missing > something trivial, or that is a manual bug. Even if it's > consistent, I think it could be more clear. This is called _jumping to conclusions_ before reading the entire presentation of the topic. It can be risky, as this experience shows. From debbugs-submit-bounces@debbugs.gnu.org Wed Oct 03 08:02:35 2012 Received: (at 12564) by debbugs.gnu.org; 3 Oct 2012 12:02:35 +0000 Received: from localhost ([127.0.0.1]:38797 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJNes-0006Wk-De for submit@debbugs.gnu.org; Wed, 03 Oct 2012 08:02:35 -0400 Received: from mail-yh0-f44.google.com ([209.85.213.44]:54440) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJNep-0006Wc-Jx for 12564@debbugs.gnu.org; Wed, 03 Oct 2012 08:02:32 -0400 Received: by yhq56 with SMTP id 56so660278yhq.3 for <12564@debbugs.gnu.org>; Wed, 03 Oct 2012 05:01:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:x-face:face:date:in-reply-to :message-id:user-agent:mime-version:content-type :content-transfer-encoding; bh=FiVLP4lMxtoTBXm0rMHNNJVWoM25+jKDs464mp2OWbw=; b=wDULgPbrtuJfS+idJSTI8ZbM5NT04+ynrjFDLiR3O7cKS0DEiPr4alyglOCnxVnNPf HyFtrxkDWCqDjrnt2aCjSOMk8ff3niFJcy/89plC6uc24OGmtRSE1KY4o6+mqrP+F7aY aNxybowKHwJY5MejB/Ka6coqttV7YKtvGDcoguHyyV5bCfMJPBjSjB4ZRriH8FOVnwgC HS+p664OK86Q6qWrwH2f1Ac7+qlDYwkv/+KVv8PCC7W8H3N1QvNmjQqLfemgSBJYKwQS yvdNoCziGvQ2THARYomETKgbBnsKRP9Zi0rhPonDwgLY71jRdvBMQdi3LXCVnln9GDgb IAKQ== Received: by 10.236.193.98 with SMTP id j62mr1561952yhn.35.1349265712496; Wed, 03 Oct 2012 05:01:52 -0700 (PDT) Received: from felix-laptop ([177.149.85.75]) by mx.google.com with ESMTPS id f15sm3678020anm.9.2012.10.03.05.01.49 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 03 Oct 2012 05:01:51 -0700 (PDT) From: oitofelix@gmail.com (Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro) To: "Drew Adams" Subject: Re: bug#12564: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph References: <87pq508xre.fsf@gmail.com> <9C99AC9C311D44DE8BF1FF1C75F80A24@us.oracle.com> X-Face: 7_Ue~hNu.m"-/5/ev>FarGLKlDiX4``[3h?&R$-G*_&]9YzflY_l#]w1TmN/F-qQw}7J(X1UixumC'CpK6s)); ; B#sRafjX.|!)E=ww4C)p!/=/3\:n`1#E-&^:NLH@:FM5.(Mp][s; ANa8ckwR731]}t7Me4?o$|D!Ad%(KMe],d'CB1"Z6k/HuNIAy1Yqjh7|QH*]|uNh=l#kuF1iUB$o5+>S$SjNXUcYlUF&]Ywon[H*iNY=wAh(pe,bi-Y@@_F( Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAGFBMVEX+3sEbAwPLg2fmnn6a XEb3tJf9yapIHBLaXEbrAAACXElEQVQ4jV3UwW7bMAwGYGFFfTdQwNdBUpbrIFo5twoHX4uo8tlo Ye06Bwb0+vspx8kwXwLkM0mJZKJKGcof9W2yv/Kk8NhjOCj3fFSl8PD6dHpvcoXmYld9ejY94Dw8 vb4fct7k0zDzwVgAkq0pjfMo0GTqA4fAFcrqEyhLjSZ/MuvDsEGgGLX2tUjOTmu7RayayDIy/ITk PDtt+w0MEb7H8x0hTY4u/FaFkclQTNHnL32QbDk5PqoXKyUIxSONc3qXXBfmoq7OAvyYoi3ajxOq u6GsAFxVYL5YHg0gR4vsq1rpwgI5Rm4IMLtg7LKq4hNrwu3maY6Ey+N+QQ+r6g6jDYAJ50+pyepD DxwEDMBUyIhLydFguIKvkOuDIO0vmlG8PSerTZJvU57mNKM9G1z9BtK+JqW5N6StwAuxNrXnEiQQ XYX2WqEOHDUkgjZ4eUAz7xH8H6CXzqO59wi/QfRpFhjaB8j7CMBg0w4delUjpkYW5eu0Q5EIOS1S wZ9+zA7jvsOkJhnqCEh9hU4A3Wi2Y+WPUzx2bafapbulqoAFSXHo2lYVFA811RbhtHdvpUK7Qd5W N2rqF4FFQNajITRpxBbSsW0rdCxDn3LC+mrN5zgsAu0dML+IffaXpd3BShG5oJrRw48HaJYuZtlC 9LCWuIE1JNugnmXkb/+ACwJ4HwdwNVO3gQmyDpMA2XaPwDx0j+p1rSJavsMatHHBj3VJyG0lyg3I 1p0TWHboKvTB1wXdS3Q7EJskjzveQVIRkWPCv0B0ZbkXLxXIyofjtb1Dd62AvcQPvfAN/gIYdgbl jigrZgAAAABJRU5ErkJggg== Date: Wed, 03 Oct 2012 09:04:52 -0300 In-Reply-To: <9C99AC9C311D44DE8BF1FF1C75F80A24@us.oracle.com> (Drew Adams's message of "Tue, 2 Oct 2012 13:27:59 -0700") Message-ID: <87bogj92xn.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 12564 Cc: 12564@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.1 (/) "Drew Adams" writes: >> In the paragraph's first sentence there is a reference to section 5.8 >> "Association Lists" in the same manual, where one can read in=20 >> the first paragraph: >>=20 >> An "association list", or "alist" for short, records a mapping from >> keys to values. It is a list of cons cells called=20 >> "associations": the CAR of each cons cell is the "key", and the >> CDR is the "associated value".(1) > > And where one can read the following qualification, in the eighth paragra= ph: > > In Emacs Lisp, it is _not_ an error if an element of an association > list is not a cons cell. The alist search functions simply ignore such > elements. Many other versions of Lisp signal errors in such cases. > > You have to read beyon the intro at the beginning, to get to the details. > > The intro gives the basic idea and an illustrative example. The corner c= ase > (ignoring a non-cons element vs raising an error) is mentioned later. And > that's the right presentation order, IMHO. Yes, I actually had read that paragraph, but it's a different matter. My bug report concern the association list definition that seems to be given in the first paragraph, not an Emacs Lisp implementation detail, which the 8th paragraph is about. If the 8th paragraph was something to do with the definition, we can conclude that an association list is just any list. But I think it would make the association list term useless. Independently of Emacs Lisp specific conditions, in determined functions, to signal errors, what is an association list? Lets be more concise and consider the first paragraph and the 8th that you cited. Lets suppose the first paragraph gives the definition and the eight just one reservation (what seems in fact). Then, for the manual consistence sake, that quote I had indicated as possible inconsistent, from section 20.6.1, where one can read: (Remember that in Emacs Lisp, the elements of alists do not _have_ to be conses.) has nothing to do with the definition, but with the reservation. Thus, it would be better if it were changed to something like: (Remember that in Emacs Lisp, it is _not_ an error if an element of an association list is not a cons cell.) > >> An association list is any list that has none elements or at least one >> cons cell and possibly other elements. >>=20 >> Since I don't know what is the case, either I'm missing=20 >> something trivial, or that is a manual bug. Even if it's >> consistent, I think it could be more clear. > > This is called _jumping to conclusions_ before reading the entire present= ation > of the topic. It can be risky, as this experience shows. > If you think so... --=20 ,=3D ,-_-. =3D. Bruno F=C3=A9lix Rezende Ribeiro (oitofelix) ((_/)o o(\_)) Uns o chamam de super-vaca... `-'(. .)`-' Outros de hiper-touro... \_/ Eu o chamo simplesmente: meta-gnu! From debbugs-submit-bounces@debbugs.gnu.org Wed Oct 03 08:47:49 2012 Received: (at 12564) by debbugs.gnu.org; 3 Oct 2012 12:47:49 +0000 Received: from localhost ([127.0.0.1]:38926 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJOMd-0007bD-8d for submit@debbugs.gnu.org; Wed, 03 Oct 2012 08:47:48 -0400 Received: from mail-pb0-f44.google.com ([209.85.160.44]:35307) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TJOMa-0007b5-P0 for 12564@debbugs.gnu.org; Wed, 03 Oct 2012 08:47:45 -0400 Received: by pbbro8 with SMTP id ro8so10089724pbb.3 for <12564@debbugs.gnu.org>; Wed, 03 Oct 2012 05:47:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type:content-transfer-encoding; bh=pz3BBztATBObSTGn9MC+iLUzhytB29tLaReMvYJZNQ0=; b=LLnMJfBuhf0KFITfzpGbnhHTBiP8DrfIxwiyVhturfkCWAZ1b92sFv4p0vkFXrg4IY /5e1xvxii2wGYAFEQ96NjYZwIfJ7hV9aIoM9hZ7oTzTL1wkZHvOLjJ++ce9TG769M0av 5E0UpRhLBJyim35VDM5JUDtL9AT17sNnnebNHT5J1JWlwdnPRlkAHQYFbQOe1hJU6OqA ymgxnSac8vUafhrBCLjc05UIPCzSM2iM0EaqpkwpTQc5+gY8kTwRhcXQgwyag/r2g3iJ qI3bHeoJYARNpuLvEpW5VZNRxxwgFvFZxPFGpot8rl7/96DxThOhOpmbVdFRPxO5YsZX Dmhw== Received: by 10.66.76.231 with SMTP id n7mr4724976paw.68.1349268425065; Wed, 03 Oct 2012 05:47:05 -0700 (PDT) Received: from debian-6.05 ([115.242.250.191]) by mx.google.com with ESMTPS id qf4sm2583665pbc.1.2012.10.03.05.47.02 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 03 Oct 2012 05:47:04 -0700 (PDT) From: Jambunathan K To: oitofelix@gmail.com (Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro) Subject: Re: bug#12564: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph References: <87pq508xre.fsf@gmail.com> Date: Wed, 03 Oct 2012 18:18:25 +0530 In-Reply-To: <87pq508xre.fsf@gmail.com> ("Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro"'s message of "Tue, 02 Oct 2012 16:44:21 -0300") Message-ID: <87wqz7wwkm.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 1.9 (+) 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: oitofelix@gmail.com (Bruno Félix Rezende Ribeiro) writes: > This bug report will be sent to the Bug-GNU-Emacs mailing list > and the GNU bug tracker at debbugs.gnu.org. Please check that > the From: line contains a valid email address. After a delay of up > to one day, you should receive an acknowledgement at that address. > > Please write in English if possible, as the Emacs maintainers > usually do not have translators for other languages. > > Please describe exactly what actions triggered the bug, and > the precise symptoms of the bug. If you can, give a recipe > starting from `emacs -Q': > > In GNU Emacs Lisp Reference Manual, section 20.6.1, entitled "Basic > Completion Functions", in the 5th paragraph one can read: > > If COLLECTION is an alist (*note Association Lists::), the > permissible completions are the elements of the alist that are > either strings, or conses whose CAR is a string or symbol. > Symbols are converted to strings using `symbol-name'. Other > elements of the alist are ignored. (Remember that in Emacs Lisp, > the elements of alists do not _have_ to be conses.) In > particular, a list of strings is allowed, even though we usually > do not think of such lists as alists. > > The key affirmation is "... in Emacs Lisp, the elements of alists do not > _have_ to be conses". > > In the paragraph's first sentence there is a reference to section 5.8 > "Association Lists" in the same manual, where one can read in the first > paragraph: > > An "association list", or "alist" for short, records a mapping from > keys to values. It is a list of cons cells called "associations": the > CAR of each cons cell is the "key", and the CDR is the "associated > value".(1) > > The key affirmation here is "... It is [association lists] a list of > cons cells ...". > > Hence, we conclude an association list is a list of cons cells that > doesn't need to be cons cells. If we assume the manual is consistent, > we only can infer, supposing a language abuse, the following: > > An association list is any sort of list. > > or, perhaps more appropriate, > > An association list is [...] Content analysis details: (1.9 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (kjambunathan[at]gmail.com) -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.160.44 listed in list.dnswl.org] 0.8 RCVD_IN_SORBS_WEB RBL: SORBS: sender is an abusable web server [115.242.250.191 listed in dnsbl.sorbs.net] -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 1.0 FREEMAIL_REPLY From and body contain different freemails X-Debbugs-Envelope-To: 12564 Cc: 12564@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.9 (/) oitofelix@gmail.com (Bruno F=C3=A9lix Rezende Ribeiro) writes: > This bug report will be sent to the Bug-GNU-Emacs mailing list > and the GNU bug tracker at debbugs.gnu.org. Please check that > the From: line contains a valid email address. After a delay of up > to one day, you should receive an acknowledgement at that address. > > Please write in English if possible, as the Emacs maintainers > usually do not have translators for other languages. > > Please describe exactly what actions triggered the bug, and > the precise symptoms of the bug. If you can, give a recipe > starting from `emacs -Q': > > In GNU Emacs Lisp Reference Manual, section 20.6.1, entitled "Basic > Completion Functions", in the 5th paragraph one can read: > > If COLLECTION is an alist (*note Association Lists::), the > permissible completions are the elements of the alist that are > either strings, or conses whose CAR is a string or symbol. > Symbols are converted to strings using `symbol-name'. Other > elements of the alist are ignored. (Remember that in Emacs Lisp, > the elements of alists do not _have_ to be conses.) In > particular, a list of strings is allowed, even though we usually > do not think of such lists as alists. > > The key affirmation is "... in Emacs Lisp, the elements of alists do not > _have_ to be conses". > > In the paragraph's first sentence there is a reference to section 5.8 > "Association Lists" in the same manual, where one can read in the first > paragraph: > > An "association list", or "alist" for short, records a mapping from > keys to values. It is a list of cons cells called "associations": the > CAR of each cons cell is the "key", and the CDR is the "associated > value".(1) > > The key affirmation here is "... It is [association lists] a list of > cons cells ...". > > Hence, we conclude an association list is a list of cons cells that > doesn't need to be cons cells. If we assume the manual is consistent, > we only can infer, supposing a language abuse, the following: > > An association list is any sort of list. > > or, perhaps more appropriate, > > An association list is any list that has none elements or at least one > cons cell and possibly other elements. > > Since I don't know what is the case, either I'm missing something trivial= , or > that is a manual bug. Even if it's consistent, I think it could be more > clear. [OT] Hoping to be of help to the OP. Maintainers please skip. I wouldn't question why you are confused. I get confused by terms like cons cells, alist, lists etc all the time. I have a mental model that I resort to when I see myself stuck or confused (See postscript below) A typical user is unlikely to get good at both Shakespeare and English alphabet together. I don't mean it in a patronizing and condescending way. The comment in the completions section that you cite, (is probably trying) to bring attention to a case that a consumer of the API shouldn't overlook or the implementor of the API has specially provided for. Do you think a footnote would be a much better? What I suggest is, you ask help in the Emacs help forum citing the particular code that you are trying to get a handle on. Once that is conquered, re-visit this bug and provide a re-write of some sentences in a way that would have helped you in the first place. ps: (If you are a C-programmer) you can visualize cons cells, alists and lists in terms of linked lists, pointers and value types. This mental model will be very useful to short-circuit the Elisp jargon altogether and work around seemingly contradictory use. > Thanks. > > In GNU Emacs 24.1.1 (i686-pc-linux-gnu, GTK+ Version 2.24.10) > of 2012-08-26 on felix-laptop > Windowing system distributor `The X.Org Foundation', version 11.0.10903000 > Configured using: > `configure 'CFLAGS=3D-pipe -O3 -march=3Datom -mtune=3Datom -mmmx -msse -= msse2 > -msse3 -mssse3 -mfpmath=3Dsse'' --=20 From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 05 03:48:59 2012 Received: (at 12564) by debbugs.gnu.org; 5 Oct 2012 07:48:59 +0000 Received: from localhost ([127.0.0.1]:55061 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TK2eZ-0001mT-3G for submit@debbugs.gnu.org; Fri, 05 Oct 2012 03:48:59 -0400 Received: from mail-pa0-f44.google.com ([209.85.220.44]:32981) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TK2eW-0001mG-Tm for 12564@debbugs.gnu.org; Fri, 05 Oct 2012 03:48:57 -0400 Received: by mail-pa0-f44.google.com with SMTP id fb11so1430553pad.3 for <12564@debbugs.gnu.org>; Fri, 05 Oct 2012 00:48:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type:content-transfer-encoding; bh=c+PugHfRGaxTzH/gzoB1MZ0zIlJQg5NNt+PxBPvG7cg=; b=jBOWHTnIZQed7nGmH7kRp4fftaPPCXbW0LRixCM1rg4GILj9zi0xGmH+MMdgwM1PIt 3Uh+oTWl4E5elAD6vPH8ga+2xu5qzEmJMewaPfPpJEHTxKzfnIEwyGIPXkSYzcbsoXDL vjE1OGPTsl90b8hFiWPFcD8pdqNYQNt2QPYgaCYpGZZ6XIVdKKoirw2KaHiTRcPCXUFn PQuTIvP3sBqX3Wty+B1zZ6PbS9DxuGUAPle2LzBrQUR9Q9Vminv6pJdCUOlciVmMFEf6 QJlQemYCZlINmhG9ze4PoKU8oBiOi0Zf/XI8JW+TqZIj9wic9ZnG1/pHbOOia0Ipewge SCKw== Received: by 10.66.81.66 with SMTP id y2mr19410031pax.62.1349423321680; Fri, 05 Oct 2012 00:48:41 -0700 (PDT) Received: from ulysses ([155.69.17.228]) by mx.google.com with ESMTPS id s9sm5627152paz.9.2012.10.05.00.48.38 (version=SSLv3 cipher=OTHER); Fri, 05 Oct 2012 00:48:40 -0700 (PDT) From: Chong Yidong To: oitofelix@gmail.com (Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro) Subject: Re: bug#12564: 24.1; Emacs Lisp Reference Manual; Confusing paragraph regarding association lists' definition; Section 20.6.1 "Basic Completion Functions"; 5th paragraph References: <87pq508xre.fsf@gmail.com> Date: Fri, 05 Oct 2012 15:48:35 +0800 In-Reply-To: <87pq508xre.fsf@gmail.com> ("Bruno =?utf-8?Q?F=C3=A9lix?= Rezende Ribeiro"'s message of "Tue, 02 Oct 2012 16:44:21 -0300") Message-ID: <87mx01uzos.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.1 (/) X-Debbugs-Envelope-To: 12564 Cc: 12564@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.1 (/) oitofelix@gmail.com (Bruno F=C3=A9lix Rezende Ribeiro) writes: > The key affirmation is "... in Emacs Lisp, the elements of alists do not > _have_ to be conses". Thanks, fixed in trunk. From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 05 03:49:01 2012 Received: (at control) by debbugs.gnu.org; 5 Oct 2012 07:49:01 +0000 Received: from localhost ([127.0.0.1]:55063 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TK2ea-0001mf-Lb for submit@debbugs.gnu.org; Fri, 05 Oct 2012 03:49:00 -0400 Received: from mail-pb0-f44.google.com ([209.85.160.44]:46470) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TK2eY-0001mI-CU for control@debbugs.gnu.org; Fri, 05 Oct 2012 03:48:59 -0400 Received: by mail-pb0-f44.google.com with SMTP id ro8so1514790pbb.3 for ; Fri, 05 Oct 2012 00:48:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:subject:date:message-id:mime-version:content-type; bh=VgGq34oVKq3GORddXW/o0swWYlBI+dNcEQtijYsoDTQ=; b=JcGsnijLpayBMNXAQSHI9WcSabHlo3OzUlqkEDe22KnJJ7Ava3v0KAqqi99abtqvU0 6Et0atTRxTvjWqI7MEWrbDY67vUd+oAHzAufPgArxe1jkEiru45aREWgt4OBmKw20dAe dg2mhQV0pA4h2sxGPNCcvVC+g7qnKUco1YjZ7m5TSbKdRbBY+KnsUIVopIBZZr1tDvlu SC7UzXlyI3gbECUYpkUxV+l/pR414/e40nipl10PXHD3yoddL2aoU9pVa7TcIlCtxTzk 1X7x+Jsz4MiWm2Bu6hulAOk21w1SV0TqBcI8tiG729zXxrfPV3XzMu1pvjiXif5tFXMI SDZg== Received: by 10.68.132.165 with SMTP id ov5mr28126632pbb.105.1349423323394; Fri, 05 Oct 2012 00:48:43 -0700 (PDT) Received: from ulysses ([155.69.17.228]) by mx.google.com with ESMTPS id pv9sm5669809pbb.67.2012.10.05.00.48.40 (version=SSLv3 cipher=OTHER); Fri, 05 Oct 2012 00:48:42 -0700 (PDT) From: Chong Yidong To: control@debbugs.gnu.org Subject: close 12564 Date: Fri, 05 Oct 2012 15:48:37 +0800 Message-ID: <87obkhickq.fsf@gnu.org> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.1 (/) 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.1 (/) close 12564 thanks From unknown Sat Sep 06 09:27:49 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 02 Nov 2012 11: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