[Rcpp-commits] r1418 - in pkg/Rcpp: . inst/include/Rcpp src

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Fri Jun 4 13:30:49 CEST 2010


Author: romain
Date: 2010-06-04 13:30:49 +0200 (Fri, 04 Jun 2010)
New Revision: 1418

Modified:
   pkg/Rcpp/DESCRIPTION
   pkg/Rcpp/inst/include/Rcpp/Module.h
   pkg/Rcpp/src/Module.cpp
Log:
try to please mingw

Modified: pkg/Rcpp/DESCRIPTION
===================================================================
--- pkg/Rcpp/DESCRIPTION	2010-06-04 10:59:24 UTC (rev 1417)
+++ pkg/Rcpp/DESCRIPTION	2010-06-04 11:30:49 UTC (rev 1418)
@@ -1,6 +1,6 @@
 Package: Rcpp
 Title: Rcpp R/C++ interface package
-Version: 0.8.0.3
+Version: 0.8.0.4
 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/Module.h
===================================================================
--- pkg/Rcpp/inst/include/Rcpp/Module.h	2010-06-04 10:59:24 UTC (rev 1417)
+++ pkg/Rcpp/inst/include/Rcpp/Module.h	2010-06-04 11:30:49 UTC (rev 1418)
@@ -69,10 +69,10 @@
 	virtual Rcpp::CharacterVector complete(){ return Rcpp::CharacterVector(0) ; }
 	virtual ~class_Base(){}
 	
-	virtual SEXP getProperty( const std::string&, SEXP ) throw(std::range_error) {
+	virtual SEXP getProperty( const std::string&, SEXP ) {
 		throw std::range_error( "cannot retrieve property" ) ;
 	}
-	virtual void setProperty( const std::string&, SEXP, SEXP) throw(std::range_error){
+	virtual void setProperty( const std::string&, SEXP, SEXP) {
 		throw std::range_error( "cannot set property" ) ;
 	}
 	
@@ -255,21 +255,26 @@
 		return out ;
 	}
 	
-	SEXP getProperty( const std::string& name, SEXP object) throw(std::range_error) {
+	SEXP getProperty( const std::string& name, SEXP object) {
+	BEGIN_RCPP
 		typename PROPERTY_MAP::iterator it = properties.find( name ) ;
 		if( it == properties.end() ){
 			throw std::range_error( "no such property" ) ; 
 		}
 		prop_class* prop =  it->second ;
 		return prop->get( XP(object) ); 
+	END_RCPP
 	}
-	void setProperty( const std::string& name, SEXP object, SEXP value) throw(std::range_error){
+	
+	void setProperty( const std::string& name, SEXP object, SEXP value)  {
+	BEGIN_RCPP
 		typename PROPERTY_MAP::iterator it = properties.find( name ) ;
 		if( it == properties.end() ){
 			throw std::range_error( "no such property" ) ; 
 		}
 		prop_class* prop =  it->second ;
 		return prop->set( XP(object), value ); 
+	END_RCPP
 	}
 
 #include <Rcpp/module/Module_Add_Property.h>

Modified: pkg/Rcpp/src/Module.cpp
===================================================================
--- pkg/Rcpp/src/Module.cpp	2010-06-04 10:59:24 UTC (rev 1417)
+++ pkg/Rcpp/src/Module.cpp	2010-06-04 11:30:49 UTC (rev 1418)
@@ -69,14 +69,11 @@
 	return cl->complete(); 
 }
 RCPP_FUNCTION_3(SEXP, CppClass__get, XP_Class cl, SEXP obj, std::string name){
-	BEGIN_RCPP
 	return cl->getProperty( name, obj ) ;
-	END_RCPP
 }
 RCPP_FUNCTION_4(SEXP, CppClass__set, XP_Class cl, SEXP obj, std::string name, SEXP value){
-	BEGIN_RCPP
 	cl->setProperty( name, obj, value ) ;
-	END_RCPP
+	return R_NilValue ;
 }
 
 



More information about the Rcpp-commits mailing list