File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -159,7 +159,7 @@ namespace Rcpp{
159159 template <typename T, int RTYPE>
160160 class Eigen_Matrix_Exporter {
161161 public:
162- Eigen_Matrix_Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_length (x)) {
162+ Eigen_Matrix_Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_xlength (x)) {
163163 if (TYPEOF (x) != RTYPE)
164164 throw std::invalid_argument (" Wrong R type for mapped vector" );
165165 if (::Rf_isMatrix (x)) {
@@ -254,7 +254,7 @@ namespace Rcpp{
254254 int d_ncol, d_nrow ;
255255
256256 public:
257- Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_length (x)) {
257+ Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_xlength (x)) {
258258 if (TYPEOF (x) != RTYPE)
259259 throw std::invalid_argument (" Wrong R type for mapped matrix" );
260260 if (::Rf_isMatrix (x)) {
@@ -274,7 +274,7 @@ namespace Rcpp{
274274 int d_ncol, d_nrow ;
275275
276276 public:
277- Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_length (x)) {
277+ Exporter (SEXP x) : vec(x), d_ncol(1 ), d_nrow(Rf_xlength (x)) {
278278 if (TYPEOF (x) != RTYPE)
279279 throw std::invalid_argument (" Wrong R type for mapped 2D array" );
280280 if (::Rf_isMatrix (x)) {
You can’t perform that action at this time.
0 commit comments