On Mon, 7 Sep 2009, John Cowan wrote:

> Andre van Tonder scripsit:
>
>> 1) In an R6RS program a macro use can precede its definition,
>
> How can this work in all cases, particularly since macros may expand
> into defining-forms?  Given two forms (a 1) and (b 2), either might turn
> out to expand into a macro that defines the other.

In R6 it is an error for a later macro definition to redefine whether an 
earlier use is a definition, a BEGIN, a SYNTAX-RULES form, an ellipsis, etc. 
Even hairier things can happen when the language has procedural macros, but the 
rule can be simply stated as follows:  If you have used it already, you may not 
redefine it.

In any case, macro forward-reference is probably the first thing that will have 
to go if small Scheme is to be REPL-compatible.

Andre

_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to