[Rd] Using STL containers in R/C++

Andrew Finley finle014 at umn.edu
Thu Jan 5 03:22:28 CET 2006


Hi All,
I am in the process of writing an R extension in c++ and am using several
STL containers  (e.g., vector<double>, map<int, double>, multimap<int,
double>).  I make sure to clear all these containers at the end of the
.Call.   Everything compiles and runs just fine, but I'm a bit worried
since I haven't found any other packages that use STL.

So, my question: is it OK to use the STL containers in my code?  Will the
use of this library somehow limit portability of this package? Or cause
memory management problems?

Thanks-
Andy


Andrew Finley, Research Fellow
Department of Forest Resources
College of Natural Resources
University of Minnesota
305 Green Hall
1530 Cleveland Avenue N.
St. Paul, MN 55108

Ph 612-624-1714 office
http://blue.fr.umn.edu/home
www.cnr.umn.edu/FR/people/facstaff/finley/index.html



More information about the R-devel mailing list