GNU bug report logs - #24738
26.0.50; Incorrect Edebug spec for seq-let

Previous Next

Package: emacs;

Reported by: Gemini Lasswell <gazally <at> runbox.com>

Date: Wed, 19 Oct 2016 15:46:01 UTC

Severity: normal

Found in version 26.0.50

Done: Nicolas Petton <nicolas <at> petton.fr>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 24738 in the body.
You can then email your comments to 24738 AT debbugs.gnu.org in the normal way.

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#24738; Package emacs. (Wed, 19 Oct 2016 15:46:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Gemini Lasswell <gazally <at> runbox.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 19 Oct 2016 15:46:02 GMT) Full text and rfc822 format available.

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

From: Gemini Lasswell <gazally <at> runbox.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 26.0.50; Incorrect Edebug spec for seq-let
Date: Wed, 19 Oct 2016 08:44:35 -0700
The Edebug spec for seq-let is incorrect, causing code that uses it to
not work correctly while instrumented for debugging.

To reproduce:

1. emacs -Q
2. enter the following code into *scratch*:

(defun seq-let-bug ()
  (let ((nums [1 2 3 4 5]))
    (seq-let (a b c) nums
      (message "a=%s b=%s c=%s" a b c))))

3. C-u C-M-x
4. M-: (seq-let-bug) RET

Result: a=nil b=nil c=nil
Expected result: a=1 b=2 c=3

Changing seq-let's edebug spec to (debug (sexp form body))
fixes this for me.





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24738; Package emacs. (Wed, 19 Oct 2016 17:32:02 GMT) Full text and rfc822 format available.

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

From: Gemini Lasswell <gazally <at> runbox.com>
To: 24738 <at> debbugs.gnu.org
Subject: corrections to steps to repro
Date: Wed, 19 Oct 2016 10:30:33 -0700
I left out a couple of steps, so please use this sequence to reproduce
the bug:

1. emacs -Q
2. M-: (require 'seq) RET
3. enter the following code into *scratch*:

(defun seq-let-bug ()
  (let ((nums [1 2 3 4 5]))
    (seq-let (a b c) nums
      (message "a=%s b=%s c=%s" a b c))))

4. C-u C-M-x 
5. M-: (seq-let-bug) RET
6. G

After step 5 the debugger prompt will appear, so the G is to make it
continue execution without stopping.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24738; Package emacs. (Thu, 20 Oct 2016 08:04:02 GMT) Full text and rfc822 format available.

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

From: Nicolas Petton <nicolas <at> petton.fr>
To: Gemini Lasswell <gazally <at> runbox.com>, 24738 <at> debbugs.gnu.org
Subject: Re: bug#24738: 26.0.50; Incorrect Edebug spec for seq-let
Date: Thu, 20 Oct 2016 10:03:34 +0200
[Message part 1 (text/plain, inline)]
Gemini Lasswell <gazally <at> runbox.com> writes:

Hi Gemini,

> The Edebug spec for seq-let is incorrect, causing code that uses it to
> not work correctly while instrumented for debugging.
>
> To reproduce:
>
> 1. emacs -Q
> 2. enter the following code into *scratch*:
>
> (defun seq-let-bug ()
>   (let ((nums [1 2 3 4 5]))
>     (seq-let (a b c) nums
>       (message "a=%s b=%s c=%s" a b c))))
>
> 3. C-u C-M-x
> 4. M-: (seq-let-bug) RET
>
> Result: a=nil b=nil c=nil
> Expected result: a=1 b=2 c=3

Indeed, thanks for reporting!

>
> Changing seq-let's edebug spec to (debug (sexp form body))
> fixes this for me.

Why sexp instead of form for the first argument?

Cheers,
Nico
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24738; Package emacs. (Thu, 20 Oct 2016 14:30:02 GMT) Full text and rfc822 format available.

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

From: Gemini Lasswell <gazally <at> runbox.com>
To: Nicolas Petton <nicolas <at> petton.fr>, 24738 <at> debbugs.gnu.org
Subject: Re: bug#24738: 26.0.50; Incorrect Edebug spec for seq-let
Date: Thu, 20 Oct 2016 07:29:50 -0700
Nicolas Petton <nicolas <at> petton.fr> writes:

>> Changing seq-let's edebug spec to (debug (sexp form body))
>> fixes this for me.
>
> Why sexp instead of form for the first argument?

Because it doesn't get evaluated and shouldn't be instrumented.





Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24738; Package emacs. (Thu, 20 Oct 2016 15:32:02 GMT) Full text and rfc822 format available.

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

From: Nicolas Petton <nicolas <at> petton.fr>
To: Gemini Lasswell <gazally <at> runbox.com>, 24738 <at> debbugs.gnu.org
Subject: Re: bug#24738: 26.0.50; Incorrect Edebug spec for seq-let
Date: Thu, 20 Oct 2016 17:31:39 +0200
[Message part 1 (text/plain, inline)]
Gemini Lasswell <gazally <at> runbox.com> writes:

>> Why sexp instead of form for the first argument?
>
> Because it doesn't get evaluated and shouldn't be instrumented.

Hmm, indeed :)

I'll apply your changes, thanks!

Cheers,
Nico
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#24738; Package emacs. (Mon, 24 Oct 2016 11:17:02 GMT) Full text and rfc822 format available.

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

From: Nicolas Petton <nicolas <at> petton.fr>
To: Gemini Lasswell <gazally <at> runbox.com>, 24738 <at> debbugs.gnu.org
Cc: 24738-done <at> debbugs.gnu.org
Subject: Re: bug#24738: 26.0.50; Incorrect Edebug spec for seq-let
Date: Mon, 24 Oct 2016 13:16:26 +0200
[Message part 1 (text/plain, inline)]
Gemini Lasswell <gazally <at> runbox.com> writes:

> The Edebug spec for seq-let is incorrect, causing code that uses it to
> not work correctly while instrumented for debugging.

I pushed the fix in master, thanks!

Cheers,
Nico
[signature.asc (application/pgp-signature, inline)]

Reply sent to Nicolas Petton <nicolas <at> petton.fr>:
You have taken responsibility. (Mon, 24 Oct 2016 11:17:02 GMT) Full text and rfc822 format available.

Notification sent to Gemini Lasswell <gazally <at> runbox.com>:
bug acknowledged by developer. (Mon, 24 Oct 2016 11:17:03 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 21 Nov 2016 12:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 8 years and 205 days ago.

Previous Next


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