[Rcpp-commits] r234 - pkg/src

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Dec 30 14:31:44 CET 2009


Author: romain
Date: 2009-12-30 14:31:44 +0100 (Wed, 30 Dec 2009)
New Revision: 234

Modified:
   pkg/src/RObject.cpp
Log:
did not throw the exception (what's the point), caught by unit tests

Modified: pkg/src/RObject.cpp
===================================================================
--- pkg/src/RObject.cpp	2009-12-30 13:25:32 UTC (rev 233)
+++ pkg/src/RObject.cpp	2009-12-30 13:31:44 UTC (rev 234)
@@ -294,7 +294,7 @@
     	v.assign( INTEGER(m_sexp), INTEGER(m_sexp)+n) ;
     	break;
     default:
-    	std::range_error("RObject::asStdVectorRaw expects raw, double or int");
+    	throw std::range_error("RObject::asStdVectorRaw expects raw, double or int");
     }
     return v;
 }
@@ -316,7 +316,7 @@
     	v.assign( INTEGER(m_sexp), INTEGER(m_sexp)+n) ;
     	break;
     default:
-    	std::range_error("RObject::asStdVectorDouble expects raw, double or int");
+    	throw std::range_error("RObject::asStdVectorDouble expects raw, double or int");
     }
     return v;
 }



More information about the Rcpp-commits mailing list