[Rd] How to understand packages, namespaces, environments

Gabor Grothendieck ggrothendieck at gmail.com
Mon May 9 01:46:31 CEST 2005


On 5/8/05, Mark.Bravington at csiro.au <Mark.Bravington at csiro.au> wrote:
> [Alexander Stoddard]
> > Subject: Re: [Rd] How to understand packages, namespaces, environments
> >
> > >
> > > Does saying the following load package 'foo' into its own
> > environment ?
> > >  > library(foo)
> >
> [Duncan Murdoch]
> > This loads some of the (name, object) pairs from the package into two
> > environments:  the public one the user can see, and the
> > namespace one that the code in the package can see.  They're
> > related, you don't get two copies of the objects.
> 
> That's interesting-- I thought there really were two copies. In my debug
> package, I've taken the approach of changing both copies.

How does one refer to the two different copies? Thanks.



More information about the R-devel mailing list