File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change 1+ 2025-03-07 Dirk Eddelbuettel <edd@debian.org>
2+
3+ * src/barrier.cpp (dataptr): Replace remaining DATAPTR with
4+ DATAPTR_RO for suitable R greater than 3.5.0
5+
162025-02-11 Dirk Eddelbuettel <edd@debian.org>
27
38 * R/Rcpp.package.skeleton.R (Rcpp.package.skeleton): Support optional
Original file line number Diff line number Diff line change @@ -76,7 +76,13 @@ SEXP* get_vector_ptr(SEXP x) {
7676
7777// [[Rcpp::register]]
7878void * dataptr (SEXP x) {
79+ #if R_VERSION >= R_Version(3,5,0)
80+ // DATAPTR_RO was introduced with R 3.5.0
81+ return const_cast <void *>(DATAPTR_RO (x));
82+ #else
83+ // this will get your wrists slapped under recent R CMD check ...
7984 return DATAPTR (x);
85+ #endif
8086}
8187
8288// [[Rcpp::register]]
You can’t perform that action at this time.
0 commit comments