From sfalcon at fhcrc.org  Sat Apr 14 00:43:19 2007
From: sfalcon at fhcrc.org (Seth Falcon)
Date: Fri, 13 Apr 2007 15:43:19 -0700
Subject: [Rd] how to control which version of a package library()
	installs?
In-Reply-To: <Pine.LNX.4.64.0704132252050.17244@auk.stats> (Brian Ripley's
	message of "Fri, 13 Apr 2007 23:04:00 +0100 (BST)")
References: <461FED8C.2040603@acm.org>
	<Pine.LNX.4.64.0704132204150.18247@gannet.stats.ox.ac.uk>
	<461FFA29.8040401@acm.org>
	<Pine.LNX.4.64.0704132252050.17244@auk.stats>
Message-ID: <m2wt0fhp4o.fsf@fhcrc.org>

Prof Brian Ripley <ripley at stats.ox.ac.uk> writes:
> We should try to explain this, but there is another level of complexity.
> If a package has compiled code, unloading the namespace is unlikely to 
> unload the DLL (it would need to be done explicitly in .onUnload).
> And even then, as I understand it there are OSes on which you cannot 
> really unload DLLs, and certainly cannot load another DLL of the same name 
> into the process: you get the previously loaded one.
>
> Given all the issues, I always work on the assumption that re-loading a 
> package into a R session is not going to do what I intend.

I work under the same assumption.  It would be nice if package loading
were reversible, but as you point out, there are cases where the OS
will prevent this.

The OP might also note the recent addition of an 'unload' argument to
the detach function which attempts to unload the name space and S4
methods if TRUE.  It will fail if the name space is in use by another
package.

+ seth

-- 
Seth Falcon | Computational Biology | Fred Hutchinson Cancer Research Center
http://bioconductor.org



[Rd] how to control which version of a package library() installs?
Seth Falcon