[Rcpp-commits] r804 - pkg/Rcpp/src/Rcpp

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Mar 1 14:29:36 CET 2010


Author: romain
Date: 2010-03-01 14:29:36 +0100 (Mon, 01 Mar 2010)
New Revision: 804

Modified:
   pkg/Rcpp/src/Rcpp/Named.h
Log:
minor formatting

Modified: pkg/Rcpp/src/Rcpp/Named.h
===================================================================
--- pkg/Rcpp/src/Rcpp/Named.h	2010-03-01 12:48:18 UTC (rev 803)
+++ pkg/Rcpp/src/Rcpp/Named.h	2010-03-01 13:29:36 UTC (rev 804)
@@ -50,6 +50,9 @@
 	 */
 	Named( const std::string& tag ) : object(R_NilValue), tag(tag){} ;
 	
+	template<typename T>
+	Named( const std::string& tag, const T& value ) : object(wrap(value)), tag(tag) {}
+	
 	/**
 	 * This allows the syntax : 
 	 * Language( "rnorm", Named( "mean" ) = 10 ) ;
@@ -60,11 +63,6 @@
 		return *this ;
 	}
 	
-	template<typename T>
-	Named( const std::string& tag, const T& value ) : object(), tag(tag) {
-		object = wrap( value ) ;
-	}
-	
 	SEXP getSEXP() const ; 
 	
 	std::string getTag() const ;



More information about the Rcpp-commits mailing list