emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debbugs-tracker] bug#10756: closed ([2.0.5+] Miscompilation with peval:


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#10756: closed ([2.0.5+] Miscompilation with peval: local shadows module-ref)
Date: Fri, 06 Jul 2012 18:26:02 +0000

Your message dated Fri, 06 Jul 2012 20:20:13 +0200
with message-id <address@hidden>
and subject line Re: bug#10756: [2.0.5+] Miscompilation with peval: local 
shadows module-ref
has caused the debbugs.gnu.org bug report #10756,
regarding [2.0.5+] Miscompilation with peval: local shadows module-ref
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
10756: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10756
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: [2.0.5+] Miscompilation with peval: local shadows module-ref Date: Wed, 08 Feb 2012 00:04:10 +0100 User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.93 (gnu/linux)
Hi!

Consider this:

--8<---------------cut here---------------start------------->8---
scheme@(guile-user)> ,optimize (define (foo) (define bar (@ (chbouib) bar)) bar)
$11 = (define foo
  (lambda ()
    (let ((bar-1510 (if #f #f)))
      (letrec*
        ()
        (begin (set! bar-1510 bar-1510) bar-1510)))))
--8<---------------cut here---------------end--------------->8---

Here, the ‘bar’ local is always set to *undefined*, wrongfully.

Ludo’.



--- End Message ---
--- Begin Message --- Subject: Re: bug#10756: [2.0.5+] Miscompilation with peval: local shadows module-ref Date: Fri, 06 Jul 2012 20:20:13 +0200 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux)
On Thu 08 Mar 2012 08:11, Mark H Weaver <address@hidden> writes:

>> scheme@(guile-user)> ,expand (define (foo) (define bar (@ (chbouib) bar)) 
>> bar)
>> $2 = (define foo
>>   (lambda () (letrec* ((bar-92 bar-92)) bar-92)))
>>
>> Andy
>
> I've attached a patch that fixes this bug.  Fixing '@' was literally a
> one word fix (w -> top-wrap), and the same would have been true of '@@'
> if not for the way it had been extended to support R6RS library forms.
> Unlike '@' which uses syntax->datum on the 'id' to strip the wrap, '@@'
> kept syntax objects fully intact and only changed their module.
>
> I think it was a mistake to overload '@@' to do these two different
> jobs, so I changed the R6RS-support syntax to (@@ @@ (mod ...) body) and
> left its behavior as-is, and then made (@@ (mod ...) id) act the same
> way as '@': use 'syntax->datum' on the 'id' and return top-wrap.
>
> I think it's okay to change the internal R6RS-support syntax in
> stable-2.0, because it's undocumented and only exists as a temporary
> intermediate form during macro expansion.  What do you think?
>
> Also: since 'boot-9.go' was not automatically recompiled by changing
> 'r6rs-libraries.scm', I added explicit dependencies to
> module/Makefile.am.  However, I'm almost wholly ignorant of automake, so
> please double-check what I did there.

Looks great to me, pushed.  It's strictly incompatible, but hey.  Sorry
for taking so long!  The only thing I would note is that it seems to me
that this "R6RS-support" is useful in a general sense.  Just an
impression though, I've never had occasion to use it outside the R6RS
libs.

Regards, and thanks very much,

Andy
-- 
http://wingolog.org/


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]