unloading imported modules

Andrew MacIntyre andymac at bullseye.apana.org.au
Sun Jul 21 01:23:34 EDT 2002


On 20 Jul 2002, [iso-8859-1] François Pinard wrote:

> So, when the reference count of a module drops to 0, and I get that this
> is possible, then the module is unloaded.  Isn't it?  Also, I wonder if
> a module coming from an `.so' file be effectively reloaded.  And then, if
> the previous copy (the memory area in which the `.so' is paged) gets freed?

AFAIK, dynamicly loaded extension modules (*.so, *.DLL) can't be
satisfactorily unloaded or reloaded.  While it might be possible in
theory, in practice there are all sorts of platform specific gotchas which
thwart attempts to implement this.

--
Andrew I MacIntyre                     "These thoughts are mine alone..."
E-mail: andymac at bullseye.apana.org.au  | Snail: PO Box 370
        andymac at pcug.org.au            |        Belconnen  ACT  2616
Web:    http://www.andymac.org/        |        Australia






More information about the Python-list mailing list