[Rcpp-devel] Rcpp 0.10.0
jj.allaire at gmail.com
Thu Nov 15 02:07:18 CET 2012
> 2. If my package already has a namespace named ernm, is an extra one
> wrapped around it, so that extending packages would have to use
No, the generated header file for a package exports functions within the
package namespace but that doesn't preclude other headers from exporting
other types in the same namespace.
3. Just to be clear… this removes the need to make an inline plug-in
> because you can just use cppFunction(depends="**MyPacakge",…) with no
> additional glue except for the interface statement.
> quite the opposite, // [[Rcpp::depends("myPackage")]] uses the inline
> plugin as a way to gather information about includes, libraries, ... you
> need it.
A clarification here: if your package exposes a header-only interface then
Rcpp::depends will take care of adding your package's include directory to
the sourceCpp compilation (but users of course still need to do e.g.
#include <ernm.h>). For this scenario no inline plugin is needed.
However, for cppFunction it's not enough to just add the include path, we
also need the header(s). For that case you should create a simple inline
plugiln (which you can likely create with a one-liner by calling
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Rcpp-devel