[Rcpp-commits] r742 - pkg/Rcpp/src/Rcpp/internal

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Fri Feb 19 13:20:18 CET 2010


Author: romain
Date: 2010-02-19 13:20:17 +0100 (Fri, 19 Feb 2010)
New Revision: 742

Modified:
   pkg/Rcpp/src/Rcpp/internal/wrap.h
Log:
refine the interface to deal with generic vectors properly

Modified: pkg/Rcpp/src/Rcpp/internal/wrap.h
===================================================================
--- pkg/Rcpp/src/Rcpp/internal/wrap.h	2010-02-19 12:00:51 UTC (rev 741)
+++ pkg/Rcpp/src/Rcpp/internal/wrap.h	2010-02-19 12:20:17 UTC (rev 742)
@@ -469,7 +469,7 @@
 	int size = object.size() ;
 	SEXP x = PROTECT( Rf_allocVector( VECSXP, size ) );
 	for( int i=0; i<size; i++){
-		SET_VECTOR_ELT( x, i, wrap( object.get(i) ) ) ;
+		SET_VECTOR_ELT( x, i, object.wrap(i) ) ;
 	}
 	UNPROTECT(1) ;
 	return x ;



More information about the Rcpp-commits mailing list