From ripley at stats.ox.ac.uk  Thu Feb  7 08:42:40 2013
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Thu, 07 Feb 2013 07:42:40 +0000
Subject: [Rd] How to NAMESPACE OS-specific importFrom?
In-Reply-To: <5113127B.9050407@fhcrc.org>
References: <5113127B.9050407@fhcrc.org>
Message-ID: <51135AF0.5040203@stats.ox.ac.uk>

On 07/02/2013 02:33, Martin Morgan wrote:
> I'd like to importFrom(parallel, mccollect, mcparallel) but on Windows
> these are not exported because this
>
> if(tools:::.OStype() == "unix") {
>      export(mccollect, mcparallel, mc.reset.stream, mcaffinity)
> }
>
> appears at src/library/parallel/NAMESPACE:6 of svn r61857. So should I
> be doing
>
> if (tools:::.OStype() == "unix") {
>      importFrom(parallel, mccollect, mcparallel)
> }
>
> in my NAMESPACE? I have a recollection that this has come up before,
> perhaps even in the parallel package, but I'm not able to find anything.

Yes.

Those are low-level functions in 'parallel': we provide stubs on Windows 
for user-level functions (which is where it came up before these were 
added).

> Thanks,
>
> Martin Morgan


-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595



[Rd] How to NAMESPACE OS-specific importFrom?
Prof Brian Ripley