GNU bug report logs - #25941
26.0.50; Different code behavior between using the auto-compiled and evaled versions

Previous Next

Package: emacs;

Reported by: Kaushal Modi <kaushal.modi <at> gmail.com>

Date: Thu, 2 Mar 2017 23:44:01 UTC

Severity: normal

Found in version 26.0.50

Done: Kaushal Modi <kaushal.modi <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Vibhav Pant <vibhavp <at> gmail.com>
To: Kaushal Modi <kaushal.modi <at> gmail.com>
Cc: 25941 <at> debbugs.gnu.org, Oleh Krehel <ohwoeowho <at> gmail.com>
Subject: Re: 26.0.50; Different code behavior between using the auto-compiled
 and evaled versions
Date: Thu, 9 Mar 2017 23:53:29 +0530
[Message part 1 (text/plain, inline)]
On Thu, Mar 9, 2017 at 10:01 PM, Kaushal Modi <kaushal.modi <at> gmail.com> wrote:
> This issue seems to be related to the switch bytecode change.

`cond' returns the value of the met condition when the clause doesn't
have a body. That's what seems to be happening when (eq res 'exit).
The result should be t instead of nil. A similar example like:
(defun test (v)
  (cond ((eq v 1) 'one)
((eq v 2))
(t 'none)))
Also displays different results with (test 2) when byte compiled. I've
added a patch to bytecomp.el which tries to fix this, could you apply
it and see whether the issue still exists?

Thanks,
Vibhav

-- 
Vibhav Pant
vibhavp <at> gmail.com
[condition-only-clause.diff (text/plain, attachment)]

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

Previous Next


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