[plt-scheme] determine free variables

From: Jay McCarthy (jay.mccarthy at gmail.com)
Date: Mon Mar 24 20:42:11 EDT 2008

Look at collects/web-server/lang/freevars.ss for a (syntax -> (listof
identifier-syntax)) function

(Only works on expanded code)

Jay

On Mon, Mar 24, 2008 at 5:55 PM, YC <yinso.chen at gmail.com> wrote:
> Hi all -
>
> What's the best approach to determine free variables at source level?
>
> What i am trying to accomplish is to take a scheme expression from a file,
> say
>
> (+ foo bar)
>
> and transform
>
> (lambda (foo bar)
>   (+ foo bar))
>
> for arbitrary scheme expressions.
>
> Are there procedures that would allow me to determine whether a symbol has a
> binding?  Given scheme identifier can be bound to different values, it seems
> like this would require some sort of runtime environment inspection - is
> that true?
>
> Thanks,
> yc
>
>
> _________________________________________________
>   For list-related administrative tasks:
>   http://list.cs.brown.edu/mailman/listinfo/plt-scheme
>
>



-- 
Jay McCarthy <jay.mccarthy at gmail.com>
http://jay.teammccarthy.org


Posted on the users mailing list.