Fix for Rcpp_IsNaN, given BDR's advice on R-devel