guile-devel
[Top][All Lists]
Advanced

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

Re: Programming racket like in guile


From: Stefan Israelsson Tampe
Subject: Re: Programming racket like in guile
Date: Sat, 23 Feb 2013 17:28:34 +0100
User-agent: KMail/4.9.4 (Linux/3.5.0-24-generic; KDE/4.9.4; x86_64; ; )

Let me illustrate the problem.

Consider macro syntax-parse written in (language racket). My view is 
that the
sourcecode for that code should just have been copied from the racket
sources in order to keep the code maintainable. Could we use that
macro from whithin a guile scheme program? sometimes but for this 
example
the syntax-parse macro uses so many features in racket syntax expander
that you simply cannot use it without copying the racket macro
framework. So you have racket macros and you have guile macros and
they do not compose.

But we would like to be able to use syntax-parse in guile
scheme. Hence we must port over the code, and I can tell you that
porting syntax-parse is not trivial. Should we mix guile syntax parse
and racket syntax parse in the same namespace.

It is the same store when it comes to porting over common lisp
ideoms. If you would like to port cl's loop macro to guile you cannot
use the sources. The reason is that cl uses tagbody and tagbody is not
supported in tree-il. So you write a separate port in scheme with 
syntax-parse and friends and use that. On the other hand I had a
though of extending tree-il with a tagbody form and use that as a
separate language, again macros would not compose and the same issue
will appear. 

Say that we manage to unify the macrology, no problem, then we can
just use re-export.

Hope this show some light on the problem
/Stefan




reply via email to

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