From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Philipp Stephani
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Mon, 20 Apr 2020 00:34:02 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: report 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords:
To: 40727@debbugs.gnu.org
X-Debbugs-Original-To: bug-gnu-emacs@gnu.org
Received: via spool by submit@debbugs.gnu.org id=B.158734284120980
(code B ref -1); Mon, 20 Apr 2020 00:34:02 +0000
Received: (at submit) by debbugs.gnu.org; 20 Apr 2020 00:34:01 +0000
Received: from localhost ([127.0.0.1]:46269 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jQKNs-0005SK-K0
for submit@debbugs.gnu.org; Sun, 19 Apr 2020 20:34:01 -0400
Received: from lists.gnu.org ([209.51.188.17]:35722)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from ) id 1jQKNq-0005SC-1m
for submit@debbugs.gnu.org; Sun, 19 Apr 2020 20:33:59 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:53478 helo=eggs1p.gnu.org)
by lists.gnu.org with esmtp (Exim 4.90_1)
(envelope-from ) id 1jQKNp-0005MA-Ch
for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 20:33:57 -0400
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on eggs.gnu.org
X-Spam-Level:
X-Spam-Status: No, score=-1.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,
DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_ENVFROM_END_DIGIT,
FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,URIBL_BLOCKED
autolearn=unavailable autolearn_force=no version=3.4.2
Received: from Debian-exim by eggs1p.gnu.org with spam-scanned (Exim 4.90_1)
(envelope-from ) id 1jQKNn-0007YR-SU
for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 20:33:56 -0400
Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]:55151)
by eggs1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
(Exim 4.90_1) (envelope-from )
id 1jQKNn-0007XI-DM
for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 20:33:55 -0400
Received: by mail-wm1-x333.google.com with SMTP id h2so9081729wmb.4
for ; Sun, 19 Apr 2020 17:33:55 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=from:to:subject:date:message-id:mime-version
:content-transfer-encoding;
bh=XFV+WOIdzN9GgwR3ykqUb1ZkSdYCoRkFbGtNkilrWmA=;
b=pK4H5JMD8mhlg8DGDS5Ees5qQoN0du/zRmEzCBpAe7dfZysEucOqEPPpZ6j93Z07TH
59ZqSt3eKnKN/upWXZ4FmDSRNIDlGi1jfl563cFDRmvUDGlO0XJnj1Jmj4KV17faF5ye
+xcS5yd7qgpQPTEfhrfZ7cP6IbWs+vTWsbzcAN1nNpQt1ZwqOrBV+1s6fvgzVYGY7krK
zIiQ+RT68RpQVVRZdi1XERY5vC/vKqm7kiL9Vw59cBLod5R+C07vBbJk2T+OCRbPm9aZ
DdZR6+wwTHf5J254f14ivtibCupssQwX8DHwQbBmwXpGWFNr8xxZM5/lZRbLRBDNCwdy
3aGw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:from:to:subject:date:message-id:mime-version
:content-transfer-encoding;
bh=XFV+WOIdzN9GgwR3ykqUb1ZkSdYCoRkFbGtNkilrWmA=;
b=eWKqHg5840Rk+exklUhYZ3x9huF0jg+3h1mqhogS6NEicrKXh2UeZo2eo9zBAfdHr1
NU7JWa01AnJY0chjPE3dGVEyaiERNMUEMiIixuJeJnMyHukZ6W3NBjT+htCrsGZ+c6DM
5vPTLzZjAM3y5qYPeo3vFG/p9651wbg+j7ijI61Lt9MvQR0aFjW+gIwsv8fBFV4azbRt
K/HkiAj+w5jVBybfu7FKm6dNrD9HC5X9usppGqxWgZn1GbYsUI6SSSX1UR/HBWvQOnDr
SdQlSyvp2ubqaTDaSAr016iIluQKZq7gvd3oIn308HukSuEl6O2j64dolZrMuaWuW/E/
OyWw==
X-Gm-Message-State: AGi0PuYslsUoGdTvEIwMuEnSGf4guFzXx1wMF0hvyhvlWF2ji/KjQ5b7
ma3SlsPtvG8fsy98iKKnbbR1TwXmcAc=
X-Google-Smtp-Source: APiQypIm1NGt2VlUYqNq/pJeeEzagDwqHl2t0Vv2JYjDDafX0cK0fDRWqX0hSpi4PVMtsZJkOAYhdg==
X-Received: by 2002:a1c:3281:: with SMTP id y123mr14737642wmy.30.1587342833341;
Sun, 19 Apr 2020 17:33:53 -0700 (PDT)
Received: from phst1 ([2a02:2455:2a2:100:c351:ffcc:5d8e:4288])
by smtp.gmail.com with ESMTPSA id j11sm21085502wrr.62.2020.04.19.17.33.52
for
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Sun, 19 Apr 2020 17:33:52 -0700 (PDT)
From: Philipp Stephani
Date: Mon, 20 Apr 2020 02:33:51 +0200
Message-ID:
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass client-ip=2a00:1450:4864:20::333;
envelope-from=p.stephani2@gmail.com; helo=mail-wm1-x333.google.com
X-detected-operating-system: by eggs1p.gnu.org: Genre and OS details not
recognized.
X-Received-From: 2a00:1450:4864:20::333
X-Spam-Score: 2.5 (++)
X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org",
has NOT identified this incoming email as spam. The original
message has been attached to this so you can view it or label
similar future email. If you have any questions, see
the administrator of that system for details.
Content preview: In Emacs 26: emacs -Q -batch -l cl-lib -eval '(cl-loop for
x across [1 2] and y across [3 4])' works (i.e. no error), but in Emacs 27
it gives an error
Content analysis details: (2.5 points, 10.0 required)
pts rule name description
---- ---------------------- --------------------------------------------------
0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was
blocked. See
http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block
for more information. [URIs: x.org]
0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail
provider (p.stephani2[at]gmail.com)
0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record
0.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends
in digit (p.stephani2[at]gmail.com)
1.0 SPF_SOFTFAIL SPF: sender does not match SPF record (softfail)
-0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at https://www.dnswl.org/,
low trust [209.51.188.17 listed in list.dnswl.org]
2.0 SPOOFED_FREEMAIL No description available.
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -0.5 (/)
In Emacs 26:
emacs -Q -batch -l cl-lib -eval '(cl-loop for x across [1 2] and y across [=
3 4])'
works (i.e. no error), but in Emacs 27 it gives an error
Symbol=E2=80=99s value as variable is void: --cl-vec--
This doesn't happen with "for" instead of "and", and also doesn't happen
with lists and "in". If it helps, here's the backtrace:
(length --cl-vec--)
(let ((--cl-vec-- [1 2]) (--cl-len-- (length --cl-vec--)) (--cl-idx-- -1)=
(x nil) (--cl-vec-- [3 4]) (--cl-len-- (length --cl-vec--)) (--cl-idx-- -1=
) (y nil)) (while (and (< (setq --cl-idx-- (1+ --cl-idx--)) --cl-len--) (< =
(setq --cl-idx-- (1+ --cl-idx--)) --cl-len--)) (cl-psetq x (aref --cl-vec--=
--cl-idx--) y (aref --cl-vec-- --cl-idx--))) nil)
(catch '--cl-block-nil-- (let ((--cl-vec-- [1 2]) (--cl-len-- (length --c=
l-vec--)) (--cl-idx-- -1) (x nil) (--cl-vec-- [3 4]) (--cl-len-- (length --=
cl-vec--)) (--cl-idx-- -1) (y nil)) (while (and (< (setq --cl-idx-- (1+ --c=
l-idx--)) --cl-len--) (< (setq --cl-idx-- (1+ --cl-idx--)) --cl-len--)) (cl=
-psetq x (aref --cl-vec-- --cl-idx--) y (aref --cl-vec-- --cl-idx--))) nil))
(cl--block-wrapper (catch '--cl-block-nil-- (let ((--cl-vec-- [1 2]) (--c=
l-len-- (length --cl-vec--)) (--cl-idx-- -1) (x nil) (--cl-vec-- [3 4]) (--=
cl-len-- (length --cl-vec--)) (--cl-idx-- -1) (y nil)) (while (and (< (setq=
--cl-idx-- (1+ --cl-idx--)) --cl-len--) (< (setq --cl-idx-- (1+ --cl-idx--=
)) --cl-len--)) (cl-psetq x (aref --cl-vec-- --cl-idx--) y (aref --cl-vec--=
--cl-idx--))) nil)))
(cl-block nil (let ((--cl-vec-- [1 2]) (--cl-len-- (length --cl-vec--)) (=
--cl-idx-- -1) (x nil) (--cl-vec-- [3 4]) (--cl-len-- (length --cl-vec--)) =
(--cl-idx-- -1) (y nil)) (while (and (< (setq --cl-idx-- (1+ --cl-idx--)) -=
-cl-len--) (< (setq --cl-idx-- (1+ --cl-idx--)) --cl-len--)) (cl-psetq x (a=
ref --cl-vec-- --cl-idx--) y (aref --cl-vec-- --cl-idx--))) nil))
(cl-loop for x across [1 2] and y across [3 4])
eval((cl-loop for x across [1 2] and y across [3 4]) t)
command-line-1(("-f" "toggle-debug-on-error" "-l" "cl-lib" "-eval" "(cl-l=
oop for x across [1 2] and y across [3 4])"))
command-line()
normal-top-level()
In GNU Emacs 27.0.91 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.24.13)
of 2020-04-20
Repository revision: a1040861f118881004f59866111f64cd0ae03b7a
Repository branch: emacs-27
Windowing system distributor 'The X.Org Foundation', version 11.0.12004000
System Description: Debian GNU/Linux rodete
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Configured using:
'configure --enable-checking=3Dall --enable-gtk-deprecation-warnings
--enable-gcc-warnings=3Dwarn-only --enable-check-lisp-object-type
--with-mailutils --without-pop 'CFLAGS=3D-O0 -g3' LDFLAGS=3D-g3'
Configured features:
XPM JPEG TIFF GIF PNG SOUND DBUS GSETTINGS GLIB NOTIFY INOTIFY
LIBSELINUX GNUTLS FREETYPE HARFBUZZ XFT ZLIB TOOLKIT_SCROLL_BARS GTK3
X11 XDBE XIM MODULES THREADS PDUMPER GMP
Important settings:
value of $LANG: en_US.UTF-8
locale-coding-system: utf-8-unix
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
global-eldoc-mode: t
eldoc-mode: t
electric-indent-mode: t
mouse-wheel-mode: t
tool-bar-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Load-path shadows:
None found.
Features:
(shadow sort mail-extr emacsbug message rmc dired dired-loaddefs
format-spec rfc822 mml easymenu mml-sec epa epg epg-config gnus-util
rmail rmail-loaddefs text-property-search time-date mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils phst skeleton
derived edmacro kmacro pcase ffap thingatpt url url-proxy url-privacy
url-expand url-methods url-history url-cookie url-domsuf url-util
url-parse auth-source cl-seq eieio eieio-core cl-macs eieio-loaddefs
password-cache json map url-vars mailcap subr-x rx gnutls puny seq
byte-opt gv bytecomp byte-compile cconv dbus xml cl-loaddefs cl-lib
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel term/x-win x-win term/common-win x-dnd tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch
timer select scroll-bar mouse jit-lock font-lock syntax facemenu
font-core term/tty-colors frame minibuffer cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european
ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice loaddefs button faces cus-face macroexp files
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget hashtable-print-readable backquote threads dbusbind
inotify dynamic-setting system-font-setting font-render-setting
move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)
Memory information:
((conses 16 63095 5761)
(symbols 48 8435 1)
(strings 32 22388 1823)
(string-bytes 1 711569)
(vectors 16 12506)
(vector-slots 8 174130 5982)
(floats 8 25 34)
(intervals 56 201 0)
(buffers 1000 12))
--=20
Google Germany GmbH
Erika-Mann-Stra=C3=9Fe 33
80636 M=C3=BCnchen
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Gesch=C3=A4ftsf=C3=BChrer: Paul Manicle, Halimah DeLaine Prado
If you received this communication by mistake, please don=E2=80=99t forward=
it to
anyone else (it may contain confidential or privileged information), please
erase all copies of it, including all attachments, and please let the sender
know it went to the wrong person. Thanks.
From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Noam Postavsky
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Thu, 30 Apr 2020 12:32:02 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords:
To: Philipp Stephani
Cc: 40727@debbugs.gnu.org, Tino Calancha
Received: via spool by 40727-submit@debbugs.gnu.org id=B40727.158824986925437
(code B ref 40727); Thu, 30 Apr 2020 12:32:02 +0000
Received: (at 40727) by debbugs.gnu.org; 30 Apr 2020 12:31:09 +0000
Received: from localhost ([127.0.0.1]:45457 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jU8LM-0006c8-KD
for submit@debbugs.gnu.org; Thu, 30 Apr 2020 08:31:09 -0400
Received: from mail-qk1-f174.google.com ([209.85.222.174]:43124)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jU8LI-0006bX-LS; Thu, 30 Apr 2020 08:31:06 -0400
Received: by mail-qk1-f174.google.com with SMTP id i136so1319429qke.10;
Thu, 30 Apr 2020 05:31:04 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=from:to:cc:subject:references:date:in-reply-to:message-id
:user-agent:mime-version;
bh=3zTahG8uUyLO/Q1F26RwL0FvRiMMdzXakkkFRy8P3js=;
b=TZ+8cePwm7QjOejc/YMGX+dc7jeh5G9WDa1VDeNpeIU7+9Xlf/97VeTkNvoy3U9Fsw
qZwuRoGy/aCJT4fHfv3ExgPrcJr+nMKpXdiDK3RMEx9h6Y2Pt3M93NWTRV8A5M/qRUpu
cdTJ9lhDVgLcMSGNrfF7geJzqNm0Tqzg59hwxTHCEaZd5RIewIPge53QqQxoWcChZtTX
xAkwKTX0W1bdrFwJNLpzMmPNoYmnijoBRtqFGrDzKILnuXaE548u9wON5xE2tAj8Plrb
2mHaaSraZca4E+pPZBrwtZqQpSYoWsxLJrpC52gMy/Fsz+8LGldF8alhl35uaj/LSXqz
5GgQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
:message-id:user-agent:mime-version;
bh=3zTahG8uUyLO/Q1F26RwL0FvRiMMdzXakkkFRy8P3js=;
b=gWkmSMZDk1fgGlINZ2Av4H21jNlBZBraR0YaQAkADRIAF6WSxeOxtYCoFSJadg6e38
80CCdiYZjfntHS6LCqFneBirmelHpYjwqVQM1cOddJSbFDIMMIcY0d7tPqVGGnZeEZlT
sDvGuFYKM7DnUV0itTxsIDxRmxeaRnrhbwfI+80Mbb7iPDJyz+lDAzzuc2sk9XaOdxMf
uvVXbMThk7gQpMAveJAsiCn6tzMjM/ZIkc2/bmQ+3ixLQbs6EUGWt21hEjyAUirbEJ/u
lvoR5Oh32jVjFXXR5H5ZCTuafsAvXnC1QHrnS0K1XGpsHV6XUlHUjWj2Ld+txGir3iaa
vBAw==
X-Gm-Message-State: AGi0PuauscBonuUCRWzJ459bgDzE5yl2/VQvnoIjKZLhfGR4tYjlEj/B
+EG6Cd7/grtv0MKzh9BH8//ru9Us
X-Google-Smtp-Source: APiQypICCUo6+j2J4ZZyNFgkY4EnfcYMZtzivp4R2cZNX8oDMCbix/kr88rnlcvwzhSnDbaLiBAtgQ==
X-Received: by 2002:a37:a0c7:: with SMTP id j190mr3134353qke.461.1588249858789;
Thu, 30 Apr 2020 05:30:58 -0700 (PDT)
Received: from minid (cbl-45-2-119-47.yyz.frontiernetworks.ca. [45.2.119.47])
by smtp.gmail.com with ESMTPSA id
c33sm2046882qtb.76.2020.04.30.05.30.54
(version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256);
Thu, 30 Apr 2020 05:30:57 -0700 (PDT)
From: Noam Postavsky
References:
Date: Thu, 30 Apr 2020 08:30:48 -0400
In-Reply-To: (Philipp Stephani's message of "Mon,
20 Apr 2020 02:33:51 +0200")
Message-ID: <871ro5nojr.fsf@gmail.com>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: 0.0 (/)
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -1.0 (-)
--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
tags 40727 + confirmed
quit
Philipp Stephani writes:
> In Emacs 26:
>
> emacs -Q -batch -l cl-lib -eval '(cl-loop for x across [1 2] and y across=
[3 4])'
>
> works (i.e. no error), but in Emacs 27 it gives an error
>
> Symbol=E2=80=99s value as variable is void: --cl-vec--
>
> This doesn't happen with "for" instead of "and", and also doesn't happen
> with lists and "in".
It's because of [1: bfca19e475]. I think it should be possible to fix
by grouping the bindings put into 'loop-for-bindings', but meanwhile we
should revert that change, at least on the release branch. It doesn't
revert automatically because there was meanwhile another change to use
'cl--push-clause-loop-body' instead of 'push' on the involved lines, but
after manual fixup your example works correctly.
[1: bfca19e475]: 2018-01-08 00:33:15 +0900
cl-loop: Calculate the array length just once
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=3Dbfca19e475c01f13=
dbacc7f8b7bb1aecf46cb7e4
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0001-Revert-cl-loop-Calculate-the-array-length-just-once.patch
Content-Description: patch
>From 56a55199614b60e5ffd2968217a0d115779bb23d Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 07:54:49 -0400
Subject: [PATCH] Revert "cl-loop: Calculate the array length just once"
It fails when using 'and' (parallel bindings) for arrays (Bug#40727).
* lisp/emacs-lisp/cl-macs.el (cl--parse-loop-clause): Revert to
recomputing array length.
* test/lisp/emacs-lisp/cl-macs-tests.el (cl-macs-loop-and-arrays): New
test.
---
lisp/emacs-lisp/cl-macs.el | 14 ++++----------
test/lisp/emacs-lisp/cl-macs-tests.el | 6 ++++++
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index d56f4151df..20bd1883c3 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -1322,13 +1322,11 @@ cl--parse-loop-clause
((memq word '(across across-ref))
(let ((temp-vec (make-symbol "--cl-vec--"))
- (temp-len (make-symbol "--cl-len--"))
(temp-idx (make-symbol "--cl-idx--")))
(push (list temp-vec (pop cl--loop-args)) loop-for-bindings)
- (push (list temp-len `(length ,temp-vec)) loop-for-bindings)
(push (list temp-idx -1) loop-for-bindings)
(cl--push-clause-loop-body
- `(< (setq ,temp-idx (1+ ,temp-idx)) ,temp-len))
+ `(< (setq ,temp-idx (1+ ,temp-idx)) (length ,temp-vec)))
(if (eq word 'across-ref)
(push (list var `(aref ,temp-vec ,temp-idx))
cl--loop-symbol-macs)
@@ -1342,7 +1340,6 @@ cl--parse-loop-clause
(error "Expected `of'"))))
(seq (cl--pop2 cl--loop-args))
(temp-seq (make-symbol "--cl-seq--"))
- (temp-len (make-symbol "--cl-len--"))
(temp-idx
(if (eq (car cl--loop-args) 'using)
(if (and (= (length (cadr cl--loop-args)) 2)
@@ -1353,19 +1350,16 @@ cl--parse-loop-clause
(push (list temp-seq seq) loop-for-bindings)
(push (list temp-idx 0) loop-for-bindings)
(if ref
- (progn
+ (let ((temp-len (make-symbol "--cl-len--")))
(push (list temp-len `(length ,temp-seq))
loop-for-bindings)
(push (list var `(elt ,temp-seq ,temp-idx))
cl--loop-symbol-macs)
- (cl--push-clause-loop-body `(< ,temp-idx ,temp-len)))
- ;; Evaluate seq length just if needed, that is, when seq is not a cons.
- (push (list temp-len (or (consp seq) `(length ,temp-seq)))
- loop-for-bindings)
+ (cl--push-clause-loop-body `(< ,temp-idx ,temp-len)))
(push (list var nil) loop-for-bindings)
(cl--push-clause-loop-body `(and ,temp-seq
(or (consp ,temp-seq)
- (< ,temp-idx ,temp-len))))
+ (< ,temp-idx (length ,temp-seq)))))
(push (list var `(if (consp ,temp-seq)
(pop ,temp-seq)
(aref ,temp-seq ,temp-idx)))
diff --git a/test/lisp/emacs-lisp/cl-macs-tests.el b/test/lisp/emacs-lisp/cl-macs-tests.el
index 9ca84f156a..77609a42a9 100644
--- a/test/lisp/emacs-lisp/cl-macs-tests.el
+++ b/test/lisp/emacs-lisp/cl-macs-tests.el
@@ -39,6 +39,12 @@ cl-macs-loop-and-assignment
collect (list c b a))
'((4.0 2 1) (8.3 6 5) (10.4 9 8)))))
+(ert-deftest cl-macs-loop-and-arrays ()
+ "Bug#40727"
+ (should (equal (cl-loop for y = (- (or x 0)) and x across [1 2]
+ collect (cons x y))
+ '((1 . 0) (2 . -1)))))
+
(ert-deftest cl-macs-loop-destructure ()
(should (equal (cl-loop for (a b c) in '((1 2 4.0) (5 6 8.3) (8 9 10.4))
collect (list c b a))
--
2.11.0
--=-=-=
Content-Type: text/plain
By the way, while adding the test case I found an additional regression
involving loop termination by a 'var = ...' clause. I'll open another
bug about it soon.
--=-=-=--
From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Noam Postavsky
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Thu, 30 Apr 2020 23:42:02 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: confirmed
To: Philipp Stephani
Cc: 40727@debbugs.gnu.org, Tino Calancha
Received: via spool by 40727-submit@debbugs.gnu.org id=B40727.15882900751684
(code B ref 40727); Thu, 30 Apr 2020 23:42:02 +0000
Received: (at 40727) by debbugs.gnu.org; 30 Apr 2020 23:41:15 +0000
Received: from localhost ([127.0.0.1]:47932 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jUInq-0000R4-Fa
for submit@debbugs.gnu.org; Thu, 30 Apr 2020 19:41:15 -0400
Received: from mail-qv1-f43.google.com ([209.85.219.43]:44652)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from ) id 1jUInn-0000Qn-AV
for 40727@debbugs.gnu.org; Thu, 30 Apr 2020 19:41:13 -0400
Received: by mail-qv1-f43.google.com with SMTP id ck5so3981606qvb.11
for <40727@debbugs.gnu.org>; Thu, 30 Apr 2020 16:41:11 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=from:to:cc:subject:references:date:in-reply-to:message-id
:user-agent:mime-version;
bh=63wY5GZLczNCZnlbsNqOwDLYEuBBoO4v6xOp3OVfJlw=;
b=OhUHLQFeQdE5CYTiHKTcEbKgGZ8JumWudHHBfau/5iLiRnkh8YvVP81okIbkgqW/rw
/uY5Z/a2upC2X7l6v3K1rpHPMOUQ0h+EAITCzPQvtftbK+kqCBTMkUi+7FZq6y6lXKVW
4h59h4qZoV9Ei4rNOvb3qdEeNHg1fdGK5r2vQwSWpR5QEvBgpvLtbKeaa6qcwLsWYPrr
74jawmX0poChtITuxC5gPaMOBaaIFJludfhEu+h8x2rHhT+YuZdm8rEoA1whmL8Nx9r2
OG+Y3XG64aBLYOFLFZneaf/uinfZzhzEVYALxnLnRGMmbUPjhq8LbMhBh+aTHYMBeTzt
huAw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
:message-id:user-agent:mime-version;
bh=63wY5GZLczNCZnlbsNqOwDLYEuBBoO4v6xOp3OVfJlw=;
b=kl7C/GolUkF2n+KZBk11w3KROiCDQ56u+4qTHNqem/XnpePKaW1UX5vbUsc6cyoUYE
CyN4SmXipoTkgaUWoecO/RA/cEHChUpnhKXxOGSCkFx1pG32KRLLa8WpziqdZxs2N/3R
COjE+dcm2UabiJayIGEdS5QJnAxLeIF816EBRgt9JQnIPFkwQHqQzLc+f9xT7WA5P0jW
BY9OqqD0DWrtpEpgpskbGJi7W3uWtA/EJvxwpNMmq9dfXltddYk9dGURGGCR6vOl8dae
nnThP9xXNhB0f3eLHkN9NmpZdqmRq3y/H314DKsSvpbwgmh95CWUKTyny7Bvm6MtV/ue
w+tg==
X-Gm-Message-State: AGi0PuZhSJYXlo/YX+ICJ1LMuJcMv7U4F7TSux5xG1Mo3bvxiBxEVtbI
4By6fZX4k6IWV1A+tTJ39ho=
X-Google-Smtp-Source: APiQypIcbtYBxF7CYJ0yQCOGYaDEX3jn7s3ZKNpRILxsIf+jGsR4N0LnOgdBBDlFMsO17G7XjJ2jtA==
X-Received: by 2002:a0c:f781:: with SMTP id s1mr1532853qvn.182.1588290065575;
Thu, 30 Apr 2020 16:41:05 -0700 (PDT)
Received: from minid (cbl-45-2-119-47.yyz.frontiernetworks.ca. [45.2.119.47])
by smtp.gmail.com with ESMTPSA id
y6sm1330788qky.133.2020.04.30.16.40.54
(version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256);
Thu, 30 Apr 2020 16:41:00 -0700 (PDT)
From: Noam Postavsky
References: <871ro5nojr.fsf@gmail.com>
Date: Thu, 30 Apr 2020 19:40:43 -0400
In-Reply-To: <871ro5nojr.fsf@gmail.com> (Noam Postavsky's message of "Thu, 30
Apr 2020 08:30:48 -0400")
Message-ID: <87v9lgmtj8.fsf@gmail.com>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-Spam-Score: 0.0 (/)
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -1.0 (-)
--=-=-=
Content-Type: text/plain
Noam Postavsky writes:
> By the way, while adding the test case I found an additional regression
> involving loop termination by a 'var = ...' clause. I'll open another
> bug about it soon.
Actually, it's very closely connected (only observable after fixing the
original bug, since otherwise the necessary conditions trigger the
--cl-vec-- is void error), so I'll keep it here. When there is a
(cl-loop for VAR across ARRAY and VAR2 = ...) the array index would get
incremented twice per loop. Fixed by the patch below (applies on top of
the patch in my previous message).
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0002-Don-t-increment-array-index-in-cl-loop-twice-Bug-407.patch
Content-Description: patch
>From 62d4626a1684ec7fd7d560cdf75f1b6a5f726c37 Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 18:55:40 -0400
Subject: [PATCH 2/2] Don't increment array index in cl-loop twice (Bug#40727)
* lisp/emacs-lisp/cl-macs.el (cl--parse-loop-clause): Put the temp-idx
increment in cl--loop-body, leaving just the side-effect free testing
of the index for both cl--loop-body and cl--loop-conditions.
* test/lisp/emacs-lisp/cl-macs-tests.el (cl-macs-loop-and-arrays):
Extend test to cover this case.
---
lisp/emacs-lisp/cl-macs.el | 3 ++-
test/lisp/emacs-lisp/cl-macs-tests.el | 3 +++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index 20bd1883c3..d6997ce0d2 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -1325,8 +1325,9 @@ cl--parse-loop-clause
(temp-idx (make-symbol "--cl-idx--")))
(push (list temp-vec (pop cl--loop-args)) loop-for-bindings)
(push (list temp-idx -1) loop-for-bindings)
+ (push `(setq ,temp-idx (1+ ,temp-idx)) cl--loop-body)
(cl--push-clause-loop-body
- `(< (setq ,temp-idx (1+ ,temp-idx)) (length ,temp-vec)))
+ `(< ,temp-idx (length ,temp-vec)))
(if (eq word 'across-ref)
(push (list var `(aref ,temp-vec ,temp-idx))
cl--loop-symbol-macs)
diff --git a/test/lisp/emacs-lisp/cl-macs-tests.el b/test/lisp/emacs-lisp/cl-macs-tests.el
index 77609a42a9..983e79ac57 100644
--- a/test/lisp/emacs-lisp/cl-macs-tests.el
+++ b/test/lisp/emacs-lisp/cl-macs-tests.el
@@ -43,6 +43,9 @@ cl-macs-loop-and-arrays
"Bug#40727"
(should (equal (cl-loop for y = (- (or x 0)) and x across [1 2]
collect (cons x y))
+ '((1 . 0) (2 . -1))))
+ (should (equal (cl-loop for x across [1 2] and y = (- (or x 0))
+ collect (cons x y))
'((1 . 0) (2 . -1)))))
(ert-deftest cl-macs-loop-destructure ()
--
2.11.0
--=-=-=
Content-Type: text/plain
Eli, is it okay to push both of these to emacs-27? Alternatively,
reverting both fixes to Bug#29799 in addition to the Bug#29866 fix
works:
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0001-Revert-Refix-conditional-step-clauses-in-cl-loop.patch
Content-Description: patch
>From 431d7ebc466163808535706cbb4929b25e5b4fbc Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 19:33:34 -0400
Subject: [PATCH 1/4] Revert "Refix conditional step clauses in cl-loop"
This reverts commit 045cfbef09a67c334e4772cb045181cf2203d839.
---
lisp/emacs-lisp/cl-macs.el | 96 ++++++++++++++++++++++++++++------------------
1 file changed, 59 insertions(+), 37 deletions(-)
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index d56f4151df..cda25d186f 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -889,7 +889,7 @@ cl-return-from
;;; The "cl-loop" macro.
(defvar cl--loop-args) (defvar cl--loop-accum-var) (defvar cl--loop-accum-vars)
-(defvar cl--loop-bindings) (defvar cl--loop-body) (defvar cl--loop-conditions)
+(defvar cl--loop-bindings) (defvar cl--loop-body)
(defvar cl--loop-finally)
(defvar cl--loop-finish-flag) ;Symbol set to nil to exit the loop?
(defvar cl--loop-first-flag)
@@ -897,7 +897,7 @@ cl--loop-initially
(defvar cl--loop-name)
(defvar cl--loop-result) (defvar cl--loop-result-explicit)
(defvar cl--loop-result-var) (defvar cl--loop-steps)
-(defvar cl--loop-symbol-macs)
+(defvar cl--loop-symbol-macs) (defvar cl--loop-guard-cond)
(defun cl--loop-set-iterator-function (kind iterator)
(if cl--loop-iterator-function
@@ -966,8 +966,7 @@ cl-loop
(cl--loop-accum-var nil) (cl--loop-accum-vars nil)
(cl--loop-initially nil) (cl--loop-finally nil)
(cl--loop-iterator-function nil) (cl--loop-first-flag nil)
- (cl--loop-symbol-macs nil)
- (cl--loop-conditions nil))
+ (cl--loop-symbol-macs nil) (cl--loop-guard-cond nil))
;; Here is more or less how those dynbind vars are used after looping
;; over cl--parse-loop-clause:
;;
@@ -1002,7 +1001,24 @@ cl-loop
(list (or cl--loop-result-explicit
cl--loop-result))))
(ands (cl--loop-build-ands (nreverse cl--loop-body)))
- (while-body (nconc (cadr ands) (nreverse cl--loop-steps)))
+ (while-body
+ (nconc
+ (cadr ands)
+ (if (or (not cl--loop-guard-cond) (not cl--loop-first-flag))
+ (nreverse cl--loop-steps)
+ ;; Right after update the loop variable ensure that the loop
+ ;; condition, i.e. (car ands), is still satisfied; otherwise,
+ ;; set `cl--loop-first-flag' nil and skip the remaining
+ ;; body forms (#Bug#29799).
+ ;;
+ ;; (last cl--loop-steps) updates the loop var
+ ;; (car (butlast cl--loop-steps)) sets `cl--loop-first-flag' nil
+ ;; (nreverse (cdr (butlast cl--loop-steps))) are the
+ ;; remaining body forms.
+ (append (last cl--loop-steps)
+ `((and ,(car ands)
+ ,@(nreverse (cdr (butlast cl--loop-steps)))))
+ `(,(car (butlast cl--loop-steps)))))))
(body (append
(nreverse cl--loop-initially)
(list (if cl--loop-iterator-function
@@ -1035,12 +1051,6 @@ cl-loop
(list `(cl-symbol-macrolet ,cl--loop-symbol-macs ,@body))))
`(cl-block ,cl--loop-name ,@body)))))
-(defmacro cl--push-clause-loop-body (clause)
- "Apply CLAUSE to both `cl--loop-conditions' and `cl--loop-body'."
- `(progn
- (push ,clause cl--loop-conditions)
- (push ,clause cl--loop-body)))
-
;; Below is a complete spec for cl-loop, in several parts that correspond
;; to the syntax given in CLtL2. The specs do more than specify where
;; the forms are; it also specifies, as much as Edebug allows, all the
@@ -1191,6 +1201,8 @@ cl--push-clause-loop-body
;; (def-edebug-spec loop-d-type-spec
;; (&or (loop-d-type-spec . [&or nil loop-d-type-spec]) cl-type-spec))
+
+
(defun cl--parse-loop-clause () ; uses loop-*
(let ((word (pop cl--loop-args))
(hash-types '(hash-key hash-keys hash-value hash-values))
@@ -1269,11 +1281,11 @@ cl--parse-loop-clause
(if end-var (push (list end-var end) loop-for-bindings))
(if step-var (push (list step-var step)
loop-for-bindings))
- (when end
- (cl--push-clause-loop-body
- (list
- (if down (if excl '> '>=) (if excl '< '<=))
- var (or end-var end))))
+ (if end
+ (push (list
+ (if down (if excl '> '>=) (if excl '< '<=))
+ var (or end-var end))
+ cl--loop-body))
(push (list var (list (if down '- '+) var
(or step-var step 1)))
loop-for-steps)))
@@ -1283,7 +1295,7 @@ cl--parse-loop-clause
(temp (if (and on (symbolp var))
var (make-symbol "--cl-var--"))))
(push (list temp (pop cl--loop-args)) loop-for-bindings)
- (cl--push-clause-loop-body `(consp ,temp))
+ (push `(consp ,temp) cl--loop-body)
(if (eq word 'in-ref)
(push (list var `(car ,temp)) cl--loop-symbol-macs)
(or (eq temp var)
@@ -1306,19 +1318,24 @@ cl--parse-loop-clause
((eq word '=)
(let* ((start (pop cl--loop-args))
(then (if (eq (car cl--loop-args) 'then)
- (cl--pop2 cl--loop-args) start))
- (first-assign (or cl--loop-first-flag
- (setq cl--loop-first-flag
- (make-symbol "--cl-var--")))))
+ (cl--pop2 cl--loop-args) start)))
(push (list var nil) loop-for-bindings)
(if (or ands (eq (car cl--loop-args) 'and))
(progn
- (push `(,var (if ,first-assign ,start ,var)) loop-for-sets)
- (push `(,var (if ,(car (cl--loop-build-ands
- (nreverse cl--loop-conditions)))
- ,then ,var))
- loop-for-steps))
- (push `(,var (if ,first-assign ,start ,then)) loop-for-sets))))
+ (push `(,var
+ (if ,(or cl--loop-first-flag
+ (setq cl--loop-first-flag
+ (make-symbol "--cl-var--")))
+ ,start ,var))
+ loop-for-sets)
+ (push (list var then) loop-for-steps))
+ (push (list var
+ (if (eq start then) start
+ `(if ,(or cl--loop-first-flag
+ (setq cl--loop-first-flag
+ (make-symbol "--cl-var--")))
+ ,start ,then)))
+ loop-for-sets))))
((memq word '(across across-ref))
(let ((temp-vec (make-symbol "--cl-vec--"))
@@ -1327,8 +1344,9 @@ cl--parse-loop-clause
(push (list temp-vec (pop cl--loop-args)) loop-for-bindings)
(push (list temp-len `(length ,temp-vec)) loop-for-bindings)
(push (list temp-idx -1) loop-for-bindings)
- (cl--push-clause-loop-body
- `(< (setq ,temp-idx (1+ ,temp-idx)) ,temp-len))
+ (push `(< (setq ,temp-idx (1+ ,temp-idx))
+ ,temp-len)
+ cl--loop-body)
(if (eq word 'across-ref)
(push (list var `(aref ,temp-vec ,temp-idx))
cl--loop-symbol-macs)
@@ -1358,14 +1376,15 @@ cl--parse-loop-clause
loop-for-bindings)
(push (list var `(elt ,temp-seq ,temp-idx))
cl--loop-symbol-macs)
- (cl--push-clause-loop-body `(< ,temp-idx ,temp-len)))
+ (push `(< ,temp-idx ,temp-len) cl--loop-body))
;; Evaluate seq length just if needed, that is, when seq is not a cons.
(push (list temp-len (or (consp seq) `(length ,temp-seq)))
loop-for-bindings)
(push (list var nil) loop-for-bindings)
- (cl--push-clause-loop-body `(and ,temp-seq
- (or (consp ,temp-seq)
- (< ,temp-idx ,temp-len))))
+ (push `(and ,temp-seq
+ (or (consp ,temp-seq)
+ (< ,temp-idx ,temp-len)))
+ cl--loop-body)
(push (list var `(if (consp ,temp-seq)
(pop ,temp-seq)
(aref ,temp-seq ,temp-idx)))
@@ -1461,8 +1480,9 @@ cl--parse-loop-clause
(push (list var '(selected-frame))
loop-for-bindings)
(push (list temp nil) loop-for-bindings)
- (cl--push-clause-loop-body `(prog1 (not (eq ,var ,temp))
- (or ,temp (setq ,temp ,var))))
+ (push `(prog1 (not (eq ,var ,temp))
+ (or ,temp (setq ,temp ,var)))
+ cl--loop-body)
(push (list var `(next-frame ,var))
loop-for-steps)))
@@ -1483,8 +1503,9 @@ cl--parse-loop-clause
(push (list minip `(minibufferp (window-buffer ,var)))
loop-for-bindings)
(push (list temp nil) loop-for-bindings)
- (cl--push-clause-loop-body `(prog1 (not (eq ,var ,temp))
- (or ,temp (setq ,temp ,var))))
+ (push `(prog1 (not (eq ,var ,temp))
+ (or ,temp (setq ,temp ,var)))
+ cl--loop-body)
(push (list var `(next-window ,var ,minip))
loop-for-steps)))
@@ -1508,6 +1529,7 @@ cl--parse-loop-clause
t)
cl--loop-body))
(when loop-for-steps
+ (setq cl--loop-guard-cond t)
(push (cons (if ands 'cl-psetq 'setq)
(apply 'append (nreverse loop-for-steps)))
cl--loop-steps))))
--
2.11.0
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0002-Revert-cl-loop-Add-missing-guard-condition.patch
Content-Description: patch
>From 8982a0756c7fc4e1cffd3989509fd243989f946c Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 19:33:50 -0400
Subject: [PATCH 2/4] Revert "cl-loop: Add missing guard condition"
This reverts commit a0365437c9ee308ad7978e436631020f513b25e7.
---
lisp/emacs-lisp/cl-macs.el | 32 +++++++-------------------------
1 file changed, 7 insertions(+), 25 deletions(-)
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index cda25d186f..00f34d3fb6 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -897,7 +897,7 @@ cl--loop-initially
(defvar cl--loop-name)
(defvar cl--loop-result) (defvar cl--loop-result-explicit)
(defvar cl--loop-result-var) (defvar cl--loop-steps)
-(defvar cl--loop-symbol-macs) (defvar cl--loop-guard-cond)
+(defvar cl--loop-symbol-macs)
(defun cl--loop-set-iterator-function (kind iterator)
(if cl--loop-iterator-function
@@ -966,7 +966,7 @@ cl-loop
(cl--loop-accum-var nil) (cl--loop-accum-vars nil)
(cl--loop-initially nil) (cl--loop-finally nil)
(cl--loop-iterator-function nil) (cl--loop-first-flag nil)
- (cl--loop-symbol-macs nil) (cl--loop-guard-cond nil))
+ (cl--loop-symbol-macs nil))
;; Here is more or less how those dynbind vars are used after looping
;; over cl--parse-loop-clause:
;;
@@ -1001,24 +1001,7 @@ cl-loop
(list (or cl--loop-result-explicit
cl--loop-result))))
(ands (cl--loop-build-ands (nreverse cl--loop-body)))
- (while-body
- (nconc
- (cadr ands)
- (if (or (not cl--loop-guard-cond) (not cl--loop-first-flag))
- (nreverse cl--loop-steps)
- ;; Right after update the loop variable ensure that the loop
- ;; condition, i.e. (car ands), is still satisfied; otherwise,
- ;; set `cl--loop-first-flag' nil and skip the remaining
- ;; body forms (#Bug#29799).
- ;;
- ;; (last cl--loop-steps) updates the loop var
- ;; (car (butlast cl--loop-steps)) sets `cl--loop-first-flag' nil
- ;; (nreverse (cdr (butlast cl--loop-steps))) are the
- ;; remaining body forms.
- (append (last cl--loop-steps)
- `((and ,(car ands)
- ,@(nreverse (cdr (butlast cl--loop-steps)))))
- `(,(car (butlast cl--loop-steps)))))))
+ (while-body (nconc (cadr ands) (nreverse cl--loop-steps)))
(body (append
(nreverse cl--loop-initially)
(list (if cl--loop-iterator-function
@@ -1528,11 +1511,10 @@ cl--parse-loop-clause
,(cl--loop-let (nreverse loop-for-sets) 'setq ands)
t)
cl--loop-body))
- (when loop-for-steps
- (setq cl--loop-guard-cond t)
- (push (cons (if ands 'cl-psetq 'setq)
- (apply 'append (nreverse loop-for-steps)))
- cl--loop-steps))))
+ (if loop-for-steps
+ (push (cons (if ands 'cl-psetq 'setq)
+ (apply 'append (nreverse loop-for-steps)))
+ cl--loop-steps))))
((eq word 'repeat)
(let ((temp (make-symbol "--cl-var--")))
--
2.11.0
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0003-Revert-cl-loop-Calculate-the-array-length-just-once.patch
Content-Description: patch
>From 338c67f58b80462b02620cf77f16cb11770786c0 Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 19:33:51 -0400
Subject: [PATCH 3/4] Revert "cl-loop: Calculate the array length just once"
This reverts commit bfca19e475c01f13dbacc7f8b7bb1aecf46cb7e4.
---
lisp/emacs-lisp/cl-macs.el | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index 00f34d3fb6..78d083fcc6 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -1322,13 +1322,11 @@ cl--parse-loop-clause
((memq word '(across across-ref))
(let ((temp-vec (make-symbol "--cl-vec--"))
- (temp-len (make-symbol "--cl-len--"))
(temp-idx (make-symbol "--cl-idx--")))
(push (list temp-vec (pop cl--loop-args)) loop-for-bindings)
- (push (list temp-len `(length ,temp-vec)) loop-for-bindings)
(push (list temp-idx -1) loop-for-bindings)
(push `(< (setq ,temp-idx (1+ ,temp-idx))
- ,temp-len)
+ (length ,temp-vec))
cl--loop-body)
(if (eq word 'across-ref)
(push (list var `(aref ,temp-vec ,temp-idx))
@@ -1343,7 +1341,6 @@ cl--parse-loop-clause
(error "Expected `of'"))))
(seq (cl--pop2 cl--loop-args))
(temp-seq (make-symbol "--cl-seq--"))
- (temp-len (make-symbol "--cl-len--"))
(temp-idx
(if (eq (car cl--loop-args) 'using)
(if (and (= (length (cadr cl--loop-args)) 2)
@@ -1354,19 +1351,16 @@ cl--parse-loop-clause
(push (list temp-seq seq) loop-for-bindings)
(push (list temp-idx 0) loop-for-bindings)
(if ref
- (progn
+ (let ((temp-len (make-symbol "--cl-len--")))
(push (list temp-len `(length ,temp-seq))
loop-for-bindings)
(push (list var `(elt ,temp-seq ,temp-idx))
cl--loop-symbol-macs)
(push `(< ,temp-idx ,temp-len) cl--loop-body))
- ;; Evaluate seq length just if needed, that is, when seq is not a cons.
- (push (list temp-len (or (consp seq) `(length ,temp-seq)))
- loop-for-bindings)
(push (list var nil) loop-for-bindings)
(push `(and ,temp-seq
(or (consp ,temp-seq)
- (< ,temp-idx ,temp-len)))
+ (< ,temp-idx (length ,temp-seq))))
cl--loop-body)
(push (list var `(if (consp ,temp-seq)
(pop ,temp-seq)
--
2.11.0
--=-=-=
Content-Type: text/plain
Content-Disposition: attachment;
filename=0004-Mark-Bug-29799-tests-as-failing-since-we-reverted-th.patch
Content-Description: patch
>From 36c48b5c21278c0f42be31b7253bfed7f698b479 Mon Sep 17 00:00:00 2001
From: Noam Postavsky
Date: Thu, 30 Apr 2020 19:35:45 -0400
Subject: [PATCH 4/4] ; Mark Bug#29799 tests as failing since we reverted the
fix
* test/lisp/emacs-lisp/cl-macs-tests.el (cl-macs-loop-for-as-equals-and)
(cl-macs-loop-conditional-step-clauses): Set :expected-result to
:failed.
---
test/lisp/emacs-lisp/cl-macs-tests.el | 2 ++
1 file changed, 2 insertions(+)
diff --git a/test/lisp/emacs-lisp/cl-macs-tests.el b/test/lisp/emacs-lisp/cl-macs-tests.el
index 9ca84f156a..c357ecde95 100644
--- a/test/lisp/emacs-lisp/cl-macs-tests.el
+++ b/test/lisp/emacs-lisp/cl-macs-tests.el
@@ -498,6 +498,7 @@ cl-macs-loop-vconcat
(ert-deftest cl-macs-loop-for-as-equals-and ()
"Test for https://debbugs.gnu.org/29799 ."
+ :expected-result :failed
(let ((arr (make-vector 3 0)))
(should (equal '((0 0) (1 1) (2 2))
(cl-loop for k below 3 for x = k and z = (elt arr k)
@@ -531,6 +532,7 @@ cl-macs-test--symbol-macrolet
(ert-deftest cl-macs-loop-conditional-step-clauses ()
"These tests failed under the initial fixes in #bug#29799."
+ :expected-result :failed
(should (cl-loop for i from 1 upto 100 and j = 1 then (1+ j)
if (not (= i j))
return nil
--
2.11.0
--=-=-=--
From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Eli Zaretskii
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Fri, 01 May 2020 06:12:02 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: confirmed
To: Noam Postavsky
Cc: 40727@debbugs.gnu.org, p.stephani2@gmail.com, tino.calancha@gmail.com
Received: via spool by 40727-submit@debbugs.gnu.org id=B40727.15883135099644
(code B ref 40727); Fri, 01 May 2020 06:12:02 +0000
Received: (at 40727) by debbugs.gnu.org; 1 May 2020 06:11:49 +0000
Received: from localhost ([127.0.0.1]:48118 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jUOtp-0002VU-7L
for submit@debbugs.gnu.org; Fri, 01 May 2020 02:11:49 -0400
Received: from eggs.gnu.org ([209.51.188.92]:35346)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from ) id 1jUOtm-0002VH-VW
for 40727@debbugs.gnu.org; Fri, 01 May 2020 02:11:47 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:38182)
by eggs.gnu.org with esmtp (Exim 4.90_1)
(envelope-from )
id 1jUOth-0007Qq-OF; Fri, 01 May 2020 02:11:41 -0400
Received: from [176.228.60.248] (port=1675 helo=home-c4e4a596f7)
by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256)
(Exim 4.82) (envelope-from )
id 1jUOth-0000yn-2v; Fri, 01 May 2020 02:11:41 -0400
Date: Fri, 01 May 2020 09:11:27 +0300
Message-Id: <83ftckw5f4.fsf@gnu.org>
From: Eli Zaretskii
In-Reply-To: <87v9lgmtj8.fsf@gmail.com> (message from Noam Postavsky on Thu,
30 Apr 2020 19:40:43 -0400)
References: <871ro5nojr.fsf@gmail.com>
<87v9lgmtj8.fsf@gmail.com>
X-Spam-Score: -2.3 (--)
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -3.3 (---)
> From: Noam Postavsky
> Date: Thu, 30 Apr 2020 19:40:43 -0400
> Cc: 40727@debbugs.gnu.org, Tino Calancha
>
> Eli, is it okay to push both of these to emacs-27? Alternatively,
> reverting both fixes to Bug#29799 in addition to the Bug#29866 fix
> works:
I prefer reverting, thanks.
From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Noam Postavsky
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Wed, 06 May 2020 01:18:01 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: confirmed
To: Eli Zaretskii
Cc: 40727@debbugs.gnu.org, p.stephani2@gmail.com, tino.calancha@gmail.com
Received: via spool by 40727-submit@debbugs.gnu.org id=B40727.15887278323558
(code B ref 40727); Wed, 06 May 2020 01:18:01 +0000
Received: (at 40727) by debbugs.gnu.org; 6 May 2020 01:17:12 +0000
Received: from localhost ([127.0.0.1]:37932 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jW8gS-0000vF-0q
for submit@debbugs.gnu.org; Tue, 05 May 2020 21:17:12 -0400
Received: from mail-qk1-f175.google.com ([209.85.222.175]:41192)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jW8gP-0000uw-7i; Tue, 05 May 2020 21:17:10 -0400
Received: by mail-qk1-f175.google.com with SMTP id n14so361530qke.8;
Tue, 05 May 2020 18:17:09 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=from:to:cc:subject:references:date:in-reply-to:message-id
:user-agent:mime-version;
bh=OrzK03bg+61t2xwMnFDo20FeF6+VLLvmVYrW9sIFWXA=;
b=dnt8o6XRnT98z6otjpkv20hmtGna4RAL+Olw9Bw3LOSU84WBr9FhaQ967+/hxhR4g0
PSgv0daT43btJAMcqo9rSNxZJssf3/Dr43bTAVbqw5GT/7A07sUbMMZXuD30FTy2pTh1
QGm6VO4lR7436OqwW84Yw35NANno3yJj1cCfjNVCjDVQJQIsoDQGL0bkFTNo87kWWsbq
AdphDpivDQTCaLuphAtvzCk8ECgfNbKPNEmr8i9QVkeuCNo1WwKLo/7ZrmO/i94NKKXh
h4izN8Xk5vQm9M3UUPQro+k5aU9rP5BH8lUhS1Urj5mSmaZkG9E91v4ym90RsqpQ3iv0
oagg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to
:message-id:user-agent:mime-version;
bh=OrzK03bg+61t2xwMnFDo20FeF6+VLLvmVYrW9sIFWXA=;
b=PEO/Hz50a2Hsx+sV/kmbqpNbg6C3HeMRMgsTUxWQ008ByQAQMZFMFHdFCWLcUhjis+
BQ/+aAwhNGsfVKfkf4Zx4RynPMuQj9KNjhSvHAERWkDLDgeva/u1U4EfTr53hpArR9cz
JTJVCH2+R+XdtjLYzQKbE2xyhjU7UnC0mJ8I6sGy3qGtQIxgNt68Zzej3W01sUhyolwc
SmP1d0RYrbl0r7ObABfbUTuw8rWo94fJ+GM4BN1zHyGzF2wIrPRBdaHNV+9qMZr/TgNU
eJpTg12PghPJlF555xHmoRrj40O0iaAt9fyeXhMSfxYKRVLk7lklBCzQkF7gH02ik8uo
4JdA==
X-Gm-Message-State: AGi0PuZuM71LhpoWAfHLBXnJxi3/3b6pC4DKNShmpbSjWwm7+vGEf+8I
mCSz9crHx8OJm4eJWuOEGw1uPF7E
X-Google-Smtp-Source: APiQypLcFCpnJ4uqeqViK5zFtNo+IYGyPqcWFKWPottkJIOl+fqwz5EJS2hjr1xk4iBZq7GMFCEbog==
X-Received: by 2002:a37:c04:: with SMTP id 4mr6089972qkm.137.1588727823532;
Tue, 05 May 2020 18:17:03 -0700 (PDT)
Received: from minid (cbl-45-2-119-47.yyz.frontiernetworks.ca. [45.2.119.47])
by smtp.gmail.com with ESMTPSA id
n206sm538833qke.20.2020.05.05.18.17.01
(version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256);
Tue, 05 May 2020 18:17:02 -0700 (PDT)
From: Noam Postavsky
References: <871ro5nojr.fsf@gmail.com>
<87v9lgmtj8.fsf@gmail.com> <83ftckw5f4.fsf@gnu.org>
Date: Tue, 05 May 2020 21:16:50 -0400
In-Reply-To: <83ftckw5f4.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 01 May
2020 09:11:27 +0300")
Message-ID: <87h7wtn9q5.fsf@gmail.com>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.91 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -1.0 (-)
tags 40727 fixed
close 40727 27.1
quit
Eli Zaretskii writes:
>> From: Noam Postavsky
>> Date: Thu, 30 Apr 2020 19:40:43 -0400
>> Cc: 40727@debbugs.gnu.org, Tino Calancha
>>
>> Eli, is it okay to push both of these to emacs-27? Alternatively,
>> reverting both fixes to Bug#29799 in addition to the Bug#29866 fix
>> works:
>
> I prefer reverting, thanks.
Okay, I pushed those two to master, and reverted on emacs-27.
[1: 79e133da03]: 2020-05-05 21:07:58 -0400
Revert "Refix conditional step clauses in cl-loop"
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=79e133da034cd2d7cccfc5a6eb7db340f2dc45a8
[2: caf155c463]: 2020-05-05 21:07:58 -0400
Revert "cl-loop: Add missing guard condition"
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=caf155c4638d4704b2a099657153c9abc115720b
[3: de1b33f5a8]: 2020-05-05 21:07:58 -0400
Revert "cl-loop: Calculate the array length just once"
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=de1b33f5a8c6ceee9be59285f70370c3cb2efd34
[4: 1e09364d67]: 2020-05-05 21:07:58 -0400
; Mark Bug#29799 tests as failing since we reverted the fix
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=1e09364d677b0fb57efd18369c55e8c2d0e826f5
----
[5: 33c5dc3201]: 2020-05-05 21:05:26 -0400
Revert "cl-loop: Calculate the array length just once"
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=33c5dc3201c334703c951360dbc7e83b60db4456
[6: 721dad1829]: 2020-05-05 21:06:07 -0400
Don't increment array index in cl-loop twice (Bug#40727)
https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=721dad1829d9c641acd31201b96a0ddf827f0c89
From unknown Mon Aug 18 14:24:52 2025
X-Loop: help-debbugs@gnu.org
Subject: bug#40727: 27.0.91; 'cl-loop ... across ... and' seems broken
Resent-From: Philipp Stephani
Original-Sender: "Debbugs-submit"
Resent-CC: bug-gnu-emacs@gnu.org
Resent-Date: Sat, 09 May 2020 23:14:02 +0000
Resent-Message-ID:
Resent-Sender: help-debbugs@gnu.org
X-GNU-PR-Message: followup 40727
X-GNU-PR-Package: emacs
X-GNU-PR-Keywords: confirmed fixed
To: Noam Postavsky
Cc: Eli Zaretskii , 40727-done@debbugs.gnu.org, Tino Calancha
Received: via spool by 40727-done@debbugs.gnu.org id=D40727.158906600117948
(code D ref 40727); Sat, 09 May 2020 23:14:02 +0000
Received: (at 40727-done) by debbugs.gnu.org; 9 May 2020 23:13:21 +0000
Received: from localhost ([127.0.0.1]:48556 helo=debbugs.gnu.org)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from )
id 1jXYen-0004fQ-Gr
for submit@debbugs.gnu.org; Sat, 09 May 2020 19:13:21 -0400
Received: from mail-oi1-f179.google.com ([209.85.167.179]:43398)
by debbugs.gnu.org with esmtp (Exim 4.84_2)
(envelope-from ) id 1jXYel-0004f9-Ox
for 40727-done@debbugs.gnu.org; Sat, 09 May 2020 19:13:20 -0400
Received: by mail-oi1-f179.google.com with SMTP id j16so11874192oih.10
for <40727-done@debbugs.gnu.org>; Sat, 09 May 2020 16:13:19 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
h=mime-version:references:in-reply-to:from:date:message-id:subject:to
:cc; bh=Fs/DbFq4Iwxmd8U4hbnYxR+014zIoeJf1aITCfcoVfc=;
b=Ww804dgLJ/DVkyixQO8n26BLmZvLxpNgyj9vrX9uOhCUr+J2MISmhK+QpNfDt67BwC
vF0zcgnmYC2JOI6lG3b0UfhO3y7R+R/13OF2s4dWZAVdh7Pzg6eO26NbBz2No/1ehDgP
4LtbJYRu5Rv1ofWHWt7QAtY7J/Un3uPb2LA8wOYfgGxfV7YhI8iyh4l/Ig5F/vlMEovk
XuKE4nd1f0raB1QV1KMvDaWmIeufBBk0dqjXz0NAoCDID/RogKAFZ0iv3wJXiotpaGyz
RTEInb/nk7oxgR176MkYDLx+7ZIgtmrgecRZEZ0xhDxUpdh9C16xsUNPZTnzs11uy2oB
KKDQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20161025;
h=x-gm-message-state:mime-version:references:in-reply-to:from:date
:message-id:subject:to:cc;
bh=Fs/DbFq4Iwxmd8U4hbnYxR+014zIoeJf1aITCfcoVfc=;
b=LObVMnYxNr/CMVvwwpu7DeWpURRrggbNMfdPQ9rqebnkiVhhHC/2WNzPmLOqDg7zJi
Dhau7kkRCp9k83SvrH/udl+zgeyHyZN6Ql5/zfIdJ2+nSw6RXJjNTTrGNTz0Yy0mPjR3
BvuRi7djWiJaV4DjVi2r3jhcwMT9Lf+26dglpZ8kYMRqoSZUK2g0s9vTNPawP9YJ45AE
HSlhHmDuBsakBl6IDJg9hfr/5Nc3Ll1P/gR/lYwzc6ers823d1m4rn4PDaXXgJWDAULc
DgsXcureLRNpN+j2XJAODGRCwu/Eg1nIeKcYk3l+fhEW6/Vp+pZL6KNGOleg0KHtWiAH
Q9rA==
X-Gm-Message-State: AGi0PuacPPLaJB5CffvXav06j6j781ztbIXaV8e2zCgP4aQaK3hZkuBE
Z4HHJ3fwUW3L69hkm9tXSdsSvwWCAKt3fjmidVI=
X-Google-Smtp-Source: APiQypLaYWQsshAuywWqg+HV2yuUtB6WE5rSsHWjdsUF9XSCJFxjyzCGPPYmFesVuGU6IJfK2cqaB3seHlvPACyLMmA=
X-Received: by 2002:aca:d441:: with SMTP id l62mr15670547oig.9.1589065993952;
Sat, 09 May 2020 16:13:13 -0700 (PDT)
MIME-Version: 1.0
References: <871ro5nojr.fsf@gmail.com>
<87v9lgmtj8.fsf@gmail.com> <83ftckw5f4.fsf@gnu.org> <87h7wtn9q5.fsf@gmail.com>
In-Reply-To: <87h7wtn9q5.fsf@gmail.com>
From: Philipp Stephani
Date: Sun, 10 May 2020 01:13:02 +0200
Message-ID:
Content-Type: text/plain; charset="UTF-8"
X-Spam-Score: 0.3 (/)
X-BeenThere: debbugs-submit@debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id:
List-Unsubscribe: ,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: debbugs-submit-bounces@debbugs.gnu.org
Sender: "Debbugs-submit"
X-Spam-Score: -0.7 (/)
Am Mi., 6. Mai 2020 um 03:17 Uhr schrieb Noam Postavsky :
>
> tags 40727 fixed
> close 40727 27.1
> quit
>
> Eli Zaretskii writes:
>
> >> From: Noam Postavsky
> >> Date: Thu, 30 Apr 2020 19:40:43 -0400
> >> Cc: 40727@debbugs.gnu.org, Tino Calancha
> >>
> >> Eli, is it okay to push both of these to emacs-27? Alternatively,
> >> reverting both fixes to Bug#29799 in addition to the Bug#29866 fix
> >> works:
> >
> > I prefer reverting, thanks.
>
> Okay, I pushed those two to master, and reverted on emacs-27.
>
Thanks. Confirmed that the problem doesn't happen any more on the
release branch.