[Rcpp-commits] r1881 - in pkg/Rcpp: . inst/include/Rcpp/sugar/functions

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Jul 29 15:51:24 CEST 2010


Author: romain
Date: 2010-07-29 15:51:24 +0200 (Thu, 29 Jul 2010)
New Revision: 1881

Modified:
   pkg/Rcpp/DESCRIPTION
   pkg/Rcpp/inst/include/Rcpp/sugar/functions/pow.h
Log:
solaris/suncc iteration 2

Modified: pkg/Rcpp/DESCRIPTION
===================================================================
--- pkg/Rcpp/DESCRIPTION	2010-07-29 01:24:09 UTC (rev 1880)
+++ pkg/Rcpp/DESCRIPTION	2010-07-29 13:51:24 UTC (rev 1881)
@@ -1,6 +1,6 @@
 Package: Rcpp
 Title: Seamless R and C++ Integration
-Version: 0.8.5.2
+Version: 0.8.5.3
 Date: $Date$
 Author: Dirk Eddelbuettel and Romain Francois, with contributions 
  by Simon Urbanek, David Reiss and Douglas Bates; based on code written during 

Modified: pkg/Rcpp/inst/include/Rcpp/sugar/functions/pow.h
===================================================================
--- pkg/Rcpp/inst/include/Rcpp/sugar/functions/pow.h	2010-07-29 01:24:09 UTC (rev 1880)
+++ pkg/Rcpp/inst/include/Rcpp/sugar/functions/pow.h	2010-07-29 13:51:24 UTC (rev 1881)
@@ -32,7 +32,7 @@
 	pow__impl( EXPONENT_TYPE exponent_) : exponent(exponent_){}
 	
 	inline double get( STORAGE x) const {
-		return Rcpp::traits::is_na<RTYPE>(x) ? NA_INTEGER : pow(x, exponent) ;
+		return Rcpp::traits::is_na<RTYPE>(x) ? NA_INTEGER : ::pow(x, exponent) ;
 	}
 private:
 	EXPONENT_TYPE exponent ;
@@ -45,7 +45,7 @@
 	pow__impl( EXPONENT_TYPE exponent_) : exponent(exponent_){}
 	
 	inline double get( STORAGE x) const {
-		return pow(x, exponent) ;
+		return ::pow(x, exponent) ;
 	}
 private:
 	EXPONENT_TYPE exponent ;
@@ -57,7 +57,7 @@
 public:
 	typedef typename Rcpp::VectorBase<RTYPE,NA,T> VEC_TYPE ;
 	typedef typename Rcpp::traits::storage_type<RTYPE>::type STORAGE ;
-	typedef pow__impl<NA,RTYPE,EXPONENT_TYPE> OPERATOR ;
+	typedef pow__impl<NA,RTYPE, typename Rcpp::traits::remove_const<EXPONENT_TYPE>::type > OPERATOR ;
 	
 	Pow( const VEC_TYPE& object_, EXPONENT_TYPE exponent ) : 
 		object(object_), op(exponent) {}



More information about the Rcpp-commits mailing list