Re: apparent bug in sample implementation of SRFI 148

22 views
Skip to first unread message

John Cowan

unread,
Jul 22, 2017, 12:46:05 AM7/22/17
to William D Clinger, scheme-re...@googlegroups.com, Marc Nieper-Wißkirchen, srfi-148, Alfalfa Petrofsky


On Fri, Jul 21, 2017 at 8:53 PM, William D Clinger <wi...@ccs.neu.edu> wrote:

That, however, is not the issue.  The question is whether new definitions
obtained via macro expansion within the body are spliced into the context
of the let-syntax or letrec-syntax.  The R5RS is silent on that point.

Ah, I understand.  When I voted on this (ticket #48, ballot #2) I did not understand, but I stand by my vote.
 
As has been pointed out to me, the WG1 archives prove that a plurality of
the WG1 members who voted on this intended to require the new contour
semantics, but the R7RS (small) document fails to do that, and the R7RS
also fails to note any change from R6RS semantics in this regard.

Since this was an editorial failure, it should become an erratum.  I propose the following text as erratum 26:

Definitions appearing in the scope of a let-syntax expression after it is expanded  are scoped to the body let-syntax expression, as if the let-syntax expression were wrapped in a let-expression that binds no variables. 

Definitions appearing in the scope of a letrec-syntax expression after it is expanded  are scoped to the let-syntax expression, as if the letrec-syntax expression were wrapped in a let-expression that binds no variables. 

-- 
John Cowan          http://vrici.lojban.org/~cowan        co...@ccil.org
An observable characteristic is not necessarily a functional requirement.
        --John Hudson

Reply all
Reply to author
Forward
0 new messages