[Top][All Lists]

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

Re: how to implement mutual recursive parsers in syntax-parse

From: Stefan Israelsson Tampe
Subject: Re: how to implement mutual recursive parsers in syntax-parse
Date: Fri, 18 May 2012 23:58:49 +0200

I manage to make it work under master as well as guile-2.0
But the mutual code does not work. On the other hand what you said
some months ago was correct and I believe that we do not need special constructs
for local syntax-classes anymore which if correct is a plus.

Please read the mail again is master supposed to expand and evaluate all the syntax
defines before expanding the defines? And if a plain macro is encountered at the toplevel
it is expanded as well in the first run. I don't understand exactly how the expansion progresses so can you describe or link to a description?


On Tue, May 15, 2012 at 8:38 PM, Andy Wingo <address@hidden> wrote:
On Mon 14 May 2012 21:13, Stefan Israelsson Tampe <address@hidden> writes:

> (begin
>    (define parser-a code-a ...)
>    (define-syntax a spec-a))
> (begin
>    (define parser-b code-b ...)
>    (define-syntax b spec-b))
> In racket they manage to evaluate the define-syntax forms before the define-forms cause in the expansion
> of code-a amd code-b they need the spec's spec-a and spec-b.
> Do you have any ideas how solve this. I do have a fix for problem but it is not easy to use.

Have you tried master?  If I understand you correctly I think it should
work there.


reply via email to

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