Skip to content
Prev 8116 / 10988 Next

[Rcpp-devel] RcppEigen: Windows binary from CRAN crashes R, but not when installing from source.

Hi Henrik,

R CMD INSTALL defines the NDEBUG macro (as Writing R Extensions sec. 1.7 recommends), which disables eigen_assert. Otherwise your error is triggered here:

eigen_assert(a_lhs.cols() == a_rhs.rows()
        && "invalid matrix product"
        && "if you wanted a coeff-wise or a dot product use the respective explicit functions");

Looks like it's complaining that you're trying to transpose a scalar.

win-builder doesn't add -DNDEBUG. You can just #undef NDEBUG and it will build, but I'd leave asserts on during development to avoid any unexpected behavior.

Trimmed the rest of this message as I'm having problems with a new mail filter at work...

John