> We have "as" for this, and wrap for the other way around:
>
> f<- cxxfunction(signature(x = "integer"), plugin = "Rcpp", '
>  int x2 = as<int>(x) ;
>
>  return wrap(x2) ;
> ')

Got it - thanks!

And is there a standard for what you call the C++ equivalent of the R
arguments?  i.e. x_ = as<int>(x) ?

Hadley

-- 
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/
_______________________________________________
Rcpp-devel mailing list
Rcpp-devel@lists.r-forge.r-project.org
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel

Reply via email to