[racket] Lifting submodules
When I tried this, I was able to lift 'module+ main' successfully using
'syntax-local-lift-module-end-declaration'. I could also lift a 'module',
but then requiring the lifted module didn't work.
Sam
On Sep 13, 2013 11:25 PM, "Matthew Flatt" <mflatt at cs.utah.edu> wrote:
> Right -- there's currently no way to lift a module declaration after
> expansion starts working on expressions within a module.
>
> I think that operation could be added, and I'll look into it as soon as
> possible.
>
> At Fri, 13 Sep 2013 19:41:55 -0700, Eric Dobson wrote:
> > Which lifting function? All of the ones I found didn't do what I
> > needed when called from an expression context, as the lifted syntax
> > was also in expression context. (syntax-local-lift-expression, and
> > syntax-local-lift-module-end-declaration)
> >
> > On Fri, Sep 13, 2013 at 1:53 PM, Matthias Felleisen
> > <matthias at ccs.neu.edu> wrote:
> > >
> > > Lift the module definition to top and require in the expression
> position?
> > >
> > >
> > > On Sep 13, 2013, at 12:08 PM, Eric Dobson wrote:
> > >
> > >> I want to write a macro which generates submodules and then possibly
> > >> requires them. This is so that can easily use another language (TR)
> > >> for the expression.
> > >>
> > >> If all uses of the macro are at the top-level/module-level this is
> > >> easy and I can expand out to something like:
> > >> (begin
> > >> (module new-mod typed/racket <expr and provides>)
> > >> (require 'new-mod)
> > >> <use exports>)
> > >>
> > >> But I don't see how I can do something like this when the use is in an
> > >> expression context or an internal-definition context. Is there a way
> > >> to do this?
> > >> ____________________
> > >> Racket Users list:
> > >> http://lists.racket-lang.org/users
> > >
> > ____________________
> > Racket Users list:
> > http://lists.racket-lang.org/users
> ____________________
> Racket Users list:
> http://lists.racket-lang.org/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20130916/03ab3e17/attachment-0001.html>