[Rcpp-devel] Package Rcpp: Question conerning source code of cpp files and related question

Dirk Eddelbuettel edd at debian.org
Tue Sep 30 17:12:35 CEST 2014


On 30 September 2014 at 10:55, Jonathan Olmsted wrote:
| ​Hi, Martin.
|  
| 
|     1) Is there a way to see the source file of the "final" cpp-file? (I mean
|     is it possible to see how the //-lines are replaced and what soureCpp
|     does?)
| 
| 
| ​The code generation that happens behind the scenes can be made explicit with 
| 
| sourceCpp(file = "crossp.cpp", verbose = TRUE)

+1

Also, please read the "Rcpp Attributes" vignette to get a feel for the
transition to packages -- which are _the_ default unit of code dissemination
and deployment for R.  _Everything_ evolves around it with R, and if you want
to use a different environment (like Netbeans) make sure you allow it launch
the proper _R-centric_ commands (eg R CMD COMPILE ...) rather than a naked g++.

We write C++ code here, but we do it in the context of R. Context matters.

Tschoe mit oe,  Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org


More information about the Rcpp-devel mailing list