[racket-dev] results of dlopen (hence ffi) persistent across evaluations?

From: Eli Barzilay (eli at barzilay.org)
Date: Fri Aug 6 17:20:55 EDT 2010

On Aug  6, John Clements wrote:
> On Aug 6, 2010, at 3:28 PM, Eli Barzilay wrote:
> 
> > BTW, IIRC, there is a way to load a new copy of a library, but that
> > could be pretty bad.  Alternatively, there's probably a way to unload
> > a library, so perhaps this could be hacked -- somehow voiding all
> > references to code from it.  But I'm not sure if there's a sane way to
> > do that so other things don't break.  (Where breaking could also be
> > reloading a library over and over.)
> 
> Sounds reasonable.  May I add this text to the docs for ffi-lib? :
> 
> Note! On UNIX-based platforms, loaded libraries are associated with
> Racket or DrRacket for the duration of the process; re-evaluating
> ffi-lib will not force a re-load of the corresponding library.

Sure -- with a minor change -- remove unix-based, since it's the same
on windows.

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


Posted on the dev mailing list.