[R6RS] new syntax srfi draft, reference implementation

Michael Sperber sperber at informatik.uni-tuebingen.de
Wed May 17 15:07:42 EDT 2006


dyb at cs.indiana.edu writes:

> Through constructed programs that are passed to eval and constructed
> syntax objects returned by transformers.  The issue can also arise in
> other ways, such as through the #n= and #n# syntax, in particular
> implementations (and possibly in future reports).

I know it's a detail question, but does that mean non-datums can arise
from macro expansion?  I.e., could I quote the unspecified value by
plugging it in a quote as part of macro expansion like so:

(with-syntax ((un (unspecified)))
  (syntax (quote un)))

?

> They certainly aren't top-level, and it's handy to have a common term for
> both.  I could replace "internal definitions" with "internal or
> library-level definitions" everywhere it occurs, but that seems rather
> clumsy.  Do you have a better idea?

As it stands, they are certainly quite different.  As long as both are
included in a context, it's sufficient to talk about "definitions,"
but referring to both as internal is misleading.

>> - The description of the expansion process is much improved.  Still,
>>   the item "syntactic abstraction" is only true if the abstraction
>>   doesn't expand into a definition.
>
> I don't understand what you mean, and I don't see any problems with the
> syntactic abstraction item.  Please elaborate.

I think I still don't understand the expansion algorithm is the
problem.  To me, the clearest way to say what I understand you're
saying is to say that there are two passes, but you seem to disagree.

The text says, that, for definitions, only the rhs is expanded on the
first pass.  You also say:

>> The expander invokes the associated transformer to expand the
>> syntactic abstraction, then recursively performs whichever of these
>> actions are appropriate for the resulting form.

No, a macro might expand into a definition.  Is that macro fully
expanded, or only to the point where it is evident it is a definition?
If only to that point, that's in conflict with the above quote.  In
either case, that needs to be spelled out.

>> - In Section 3.4, first paragraph: What exactly is a "keyword
>>   reference"?
>
> A reference to a keyword, i.e., an identifier reference that resolves to a
> keyword.

I still don't get it---do you mean that it is a syntax object
representing an identifier that is a keyword?

>> - Kleene * and + are in tt, which is a bit disconcerting visually.
>
> I don't see any that are in tt.  Please let me know where you spotted them.

To me, they all look that way.  But I'm probably wrong.

> I would say not, unless we're also going to require similarly more robust
> versions of let and other derived forms.

But we are requiring that, no?

>> - Wrt. internal define---could a link to 
>>
>>   http://srfi.schemers.org/srfi-83/mail-archive/msg00081.html
>>
>>   or a more explicit discussion of the issues be included? 
>
> I'd be happy to include a more explicit discussion of the issues if you
> want to take a stab at it, 

I'll try to do that tomorrow.

-- 
Cheers =8-} Mike
Friede, Völkerverständigung und überhaupt blabla



More information about the R6RS mailing list