From 251ea2ac47b3c845b05b18227cdb872fdeb1645e Mon Sep 17 00:00:00 2001 From: Marvin Wright Date: Mon, 12 Jan 2026 11:24:19 +0100 Subject: [PATCH 1/2] add c++20 for testing --- src/Makevars | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Makevars b/src/Makevars index a77f239..016e9d5 100644 --- a/src/Makevars +++ b/src/Makevars @@ -1,2 +1,3 @@ PKG_CPPFLAGS = -DR_BUILD - +CXX_STD = CXX20 +PKG_CXXFLAGS = -std=c++20 From 57ec09a1e1086ebf0f3b13d8c1cd896ccc659194 Mon Sep 17 00:00:00 2001 From: Marvin Wright Date: Mon, 12 Jan 2026 15:13:52 +0100 Subject: [PATCH 2/2] load Rcpp instead of Rinternals --- DESCRIPTION | 2 +- src/utility.h | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index a204550..43374d4 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -27,7 +27,7 @@ Imports: Rcpp (>= 0.11.2), Matrix, methods, survival LinkingTo: Rcpp, RcppEigen Depends: R (>= 3.1) Suggests: testthat -RoxygenNote: 7.2.2 +RoxygenNote: 7.3.2 Encoding: UTF-8 NeedsCompilation: yes URL: https://github.com/bips-hb/blockForest, https://bips-hb.github.io/blockForest/ diff --git a/src/utility.h b/src/utility.h index e054850..deb6d6c 100644 --- a/src/utility.h +++ b/src/utility.h @@ -20,6 +20,10 @@ #ifndef UTILITY_H_ #define UTILITY_H_ +#ifdef R_BUILD +#include +#endif + #include #include #include @@ -28,10 +32,6 @@ #include #include -#ifdef R_BUILD -#include -#endif - #include "globals.h" #include "Data.h"