On Tue, Oct 18, 2011 at 10:59 PM, Andy Wingo <wingo@pobox.com> wrote:
On Tue 18 Oct 2011 16:32, Nala Ginrut <nalaginrut@gmail.com> writes:

> -----------------------wrong code------------------------------
> (define (func)
>    (let ((fp (open-output-file "/tmp/aaa")))
>        (eval-string "(write 123 fp)" (current-module))
>     ))
> -----------------------end code------------------------------------

`fp' is a lexical binding, not a module-level binding.  So no, this
won't work.  You won't be able to get to lexical variables via `eval'
(or `eval-string').

Andy
--
http://wingolog.org/


OK, I'll try another approach.