Imports and Depends

Posted by David Diez on Stack Overflow See other posts from Stack Overflow or by David Diez
Published on 2012-03-27T16:34:23Z Indexed on 2012/03/27 17:28 UTC
Read the original article Hit count: 394

Filed under:
|
|

I have read two recent posts that discuss Depends and Imports but I have four lingering, related questions:

  1. Suppose I want two packages to also be available to the end-user when they load in my package. Is there a good reason not to use Depends in this context? (The point here is to load all three packages via a command that loads just the one package.)

  2. Is it okay to specify a package in both the Depends and Imports fields?

  3. If a package is listed in Depends, is there a point to also listing it in Imports? Or are the benefits of Imports already negated by using Depends?

  4. [Added Question] Is the following correct? A package should be listed in the Imports field of the DESCRIPTION file if and only if the package is imported (in whole or in part) in the NAMESPACE file.

Thanks much!

David

© Stack Overflow or respective owner

Related posts about package

Related posts about imports