[plt-scheme] Comments on an alternate syntax for let?

From: Eli Barzilay (eli at barzilay.org)
Date: Wed Apr 9 12:12:51 EDT 2008

On Apr  9, Majorinc, Kazimir wrote:
> Robby Findler wrote:
> > The top-level definitions in a module are like the internal
> > definitions. Unless you're talking about the top-level outside a
> > module. And there, I'll just repeat Matthew's advice/diagnosis: it's
> > horribly broken. Avoid it.
> >   
> Unfortunately, I can't, because I use eval and it does not work in modules.
> 
> (module eval-works?
>         mzscheme
>   (define x 3)
>   (display (eval 'x)))
> (require eval-works?) ; => error

It does in v4:

  (module eval-works? scheme/base
    (define x 3)
    (define-namespace-anchor nsa)
    (display (eval 'x (namespace-anchor->namespace nsa))))

-- 
          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                  http://www.barzilay.org/                 Maze is Life!


Posted on the users mailing list.