[Rcpp-devel] Are there any C++ function name restrictions?

Asis Hallab asis.hallab at gmail.com
Thu May 30 02:41:02 CEST 2013


Dear Dirk, Hadley and Rccp Experts,

thank you very much for your input.
Unfortunately I still cannot solve my problem.

I took Dirk's advise and used Rcpp.package.skeleton(name="foobar") to
create a new Hello-World package.
Then I build and installed it with
R CMD INSTALL foobar/

>From an interactive R shell I could call the function
rcpp_hello_world() successfully.

Then the very only thing I did was changing the function name
rcpp_hello_world to
conditionalProbabilityTables in three files src/rcpp_hello_world.h,
src/rcpp_hello_world.cpp, and R/rcpp_hello_world.R

Finally I rebuild it with R CMD INSTALL foobar and could no longer
call function rcpp_hello_world() in an interactive R shell.

> rcpp_hello_world()
Error in .Call("conditionalProbabilityTables", PACKAGE = "foobar") :
"conditionalProbabilityTables" not available for .Call() for package "foobar"

I put the whole test project "foobar" to be browsed and checked out on github:
https://github.com/asishallab/foobar

Please help me resolve my issues.
Thank you very much.


More information about the Rcpp-devel mailing list