GNU bug report logs - #56416
29.0.50; cl-loop cl-psetq problem

Previous Next

Package: emacs;

Reported by: Sean Whitton <spwhitton <at> spwhitton.name>

Date: Wed, 6 Jul 2022 05:02:01 UTC

Severity: normal

Tags: confirmed

Merged with 6583

Found in versions 23.2, 24.5, 25.0.94, 29.0.50

To reply to this bug, email your comments to 56416 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#56416; Package emacs. (Wed, 06 Jul 2022 05:02:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sean Whitton <spwhitton <at> spwhitton.name>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 06 Jul 2022 05:02:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Sean Whitton <spwhitton <at> spwhitton.name>
To: bug-gnu-emacs <at> gnu.org
Subject: 29.0.50; cl-loop cl-psetq problem
Date: Tue, 05 Jul 2022 22:01:42 -0700
Evaluating

(cl-loop with list = '(1 2 3 4)

	 for l in list
	 for x = l and y = l

	 collect x)

yields (1 1 2 3) but it should yield (1 2 3 4).

-- 
Sean Whitton




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#56416; Package emacs. (Wed, 06 Jul 2022 11:42:02 GMT) Full text and rfc822 format available.

Message #8 received at 56416 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Sean Whitton <spwhitton <at> spwhitton.name>
Cc: Mattias Engdegård <mattiase <at> acm.org>,
 56416 <at> debbugs.gnu.org
Subject: Re: bug#56416: 29.0.50; cl-loop cl-psetq problem
Date: Wed, 06 Jul 2022 13:41:40 +0200
Sean Whitton <spwhitton <at> spwhitton.name> writes:

> Evaluating
>
> (cl-loop with list = '(1 2 3 4)
>
> 	 for l in list
> 	 for x = l and y = l
>
> 	 collect x)
>
> yields (1 1 2 3) but it should yield (1 2 3 4).

It's the `and' that's triggering this bug, I guess?

I seem to vaguely recall Mattias doing something about these corner
cases -- I may totally misremember, but I've added him to the CCs
anyway; perhaps he has a comment.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#56416; Package emacs. (Wed, 06 Jul 2022 16:07:02 GMT) Full text and rfc822 format available.

Message #11 received at 56416 <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: Tino Calancha <tino.calancha <at> gmail.com>,
 Noam Postavsky <npostavs <at> gmail.com>, Philipp Stephani <p.stephani2 <at> gmail.com>,
 dick <dick.r.chiang <at> gmail.com>, Sean Whitton <spwhitton <at> spwhitton.name>,
 56416 <at> debbugs.gnu.org
Subject: Re: bug#56416: 29.0.50; cl-loop cl-psetq problem
Date: Wed, 6 Jul 2022 18:06:33 +0200
6 juli 2022 kl. 13.41 skrev Lars Ingebrigtsen <larsi <at> gnus.org>:

> I seem to vaguely recall Mattias doing something about these corner
> cases

Were you thinking of 8e3868125c? That was only an optimisation for the non-parallel case, and shouldn't affect this problem.

Past work on this particular feature was done in bug#29799 and bug#40727; this bug might actually be a dup of bug#6583 (?). Better ask those who did the work at the time.





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#56416; Package emacs. (Thu, 07 Jul 2022 07:55:02 GMT) Full text and rfc822 format available.

Message #14 received at 56416 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Mattias Engdegård <mattiase <at> acm.org>
Cc: Tino Calancha <tino.calancha <at> gmail.com>,
 Noam Postavsky <npostavs <at> gmail.com>, Philipp Stephani <p.stephani2 <at> gmail.com>,
 dick <dick.r.chiang <at> gmail.com>, Sean Whitton <spwhitton <at> spwhitton.name>,
 56416 <at> debbugs.gnu.org
Subject: Re: bug#56416: 29.0.50; cl-loop cl-psetq problem
Date: Thu, 07 Jul 2022 09:53:59 +0200
Mattias Engdegård <mattiase <at> acm.org> writes:

>> I seem to vaguely recall Mattias doing something about these corner
>> cases
>
> Were you thinking of 8e3868125c? That was only an optimisation for the
> non-parallel case, and shouldn't affect this problem.

I probably just misremembered altogether...

> Past work on this particular feature was done in bug#29799 and
> bug#40727; this bug might actually be a dup of bug#6583 (?). Better
> ask those who did the work at the time.

Ah, yes, this looks like a duplicate of 6583, so I'll merge the two.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Forcibly Merged 6583 56416. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 07 Jul 2022 07:55:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#56416; Package emacs. (Thu, 07 Jul 2022 08:08:01 GMT) Full text and rfc822 format available.

Message #19 received at 56416 <at> debbugs.gnu.org (full text, mbox):

From: Mattias Engdegård <mattiase <at> acm.org>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: Tino Calancha <tino.calancha <at> gmail.com>,
 Noam Postavsky <npostavs <at> gmail.com>, Philipp Stephani <p.stephani2 <at> gmail.com>,
 dick <dick.r.chiang <at> gmail.com>, Sean Whitton <spwhitton <at> spwhitton.name>,
 56416 <at> debbugs.gnu.org
Subject: Re: bug#56416: 29.0.50; cl-loop cl-psetq problem
Date: Thu, 7 Jul 2022 10:07:28 +0200
7 juli 2022 kl. 09.53 skrev Lars Ingebrigtsen <larsi <at> gnus.org>:

> I probably just misremembered altogether...

Thanks for notifying me anyway -- the problem seems to stem from a confusion between iteration stepping vs materialising the variable value. It's a mess and I'm probably not the right man to fix it (no fan of cl-loop in general).





This bug report was last modified 2 years and 341 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.