Skip to content

Commit 1a4bc7a

Browse files
committed
a bit more on recommend importFrom in Rcpp FAQ
1 parent 6c75e85 commit 1a4bc7a

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

vignettes/rmd/Rcpp-FAQ.Rmd

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1754,10 +1754,14 @@ Rcpp Modules \citep{CRAN:Rcpp:Modules}. Some more background on the linking
17541754
requirement is [in this SO
17551755
question](https://stackoverflow.com/questions/2424836/exceptions-are-not-caught-in-gcc-program).
17561756

1757-
## My package fails with 'dataptr' (or 'enterRNGScope') not provided by Rcpp
1757+
## My package errors with "'dataptr' not provided by Rcpp"
17581758

1759-
For your package, it is generally recommended to have both `Imports:` and
1760-
`LinkingTo:` in the file `DESCRIPTION` combined with an explicit
1759+
If you see tests of your package fail with an error '... not provided by
1760+
Rcpp', frequently pointing at either `dataptr` or `enterRNGScope`, then the
1761+
\pkg{Rcpp} package may not have been initialized correctly. For your
1762+
package, it is generally recommended to have both `Imports: Rcpp` and
1763+
`LinkingTo: Rcpp` in the file `DESCRIPTION` combined with an explicit
17611764
`importFrom("Rcpp", "evalCpp")` in the file `NAMESPACE`. Doing so ensures
1762-
that certain symbols are registered when your package is loaded by R, and
1763-
that certain Rcpp functions are properly resolved.
1765+
that this symbol is registered when your package is loaded by R, and as a
1766+
side-effect certain other \pkg{Rcpp} function identifiers will also be
1767+
resolved properly.

0 commit comments

Comments
 (0)