Ok, I'll do exactly this and I'll report if I still encounter this problem in simpler programs. Thanks.
On Mon, May 6, 2013 at 7:39 PM, Dirk Eddelbuettel <[email protected]> wrote: > > On 6 May 2013 at 19:03, Matteo Fasiolo wrote: > | Sorry for the silly question, but since I'm using sourceCpp() too I > should't > | call > | getRNGstate/putRNGstate, right? > > If you use any of the random number generators provided by R via Rcpp, then > you __MUST__ also instantiate an RNGScope() object (which does this for > you). > > We documented this *very* clearly in a number of places in the > documentation. > > (And yes, sourceCpp() adds one as a courtesy but you should still add > one. The extra few nanoseconds in execution speed won't matter.) > > You report is otherwise still unreproducible at my end. > > Your program is also complex in that it does a few things. Try writing > smaller and smaller programs still exhibiting the error at your end. And > do > report back if you find something, or have questions. > > Dirk > > -- > Dirk Eddelbuettel | [email protected] | http://dirk.eddelbuettel.com >
_______________________________________________ Rcpp-devel mailing list [email protected] https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
