[plt-scheme] #%app literal does not match in syntax-case pattern
On Sat, Nov 21, 2009 at 5:14 AM, Carl Eastlund <carl.eastlund at gmail.com>wrote:
> Marco (I almost typed "Macro" in place of your name),
>
> Why do you need to use "Y" to perform the recursive expansion? Why
> not just have your #%module-begin run local-expand on a regular
> #%module-begin wrapped around the contents, and post-process the fully
> expanded result? You can go from unexpanded code to expanded code in
> one non-recursive line of code. Then you can emit whatever code you
> want. And you don't need to emit lists (in fact, emitting lists will
> give you *bad* results with respect to hygienic macro expansion) if
> you want "Scheme ASTs". Syntax objects are Scheme ASTs, and have
> source location information -- you might as well just keep the whole
> syntax object around. The only real work you'll need to do is
> replacing top level expressions and the bodies of top level
> definitions with stubs (calls to void), and that's very shallow
> processing.
>
> --Carl
>
You are right, of course. I was under the impression that local-expand only
expands the immediate subform.
I'm sorry for wasting yor time.
Marco
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20091121/e8f2f5e2/attachment.html>