From 2eb5f1aa9a82b35f89c1ec0b097369597021ade6 Mon Sep 17 00:00:00 2001 From: Michael Chirico Date: Mon, 27 May 2024 16:45:57 -0700 Subject: [PATCH 1/3] Slightly more robust pull of .Machine entries --- R/test.data.table.R | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/R/test.data.table.R b/R/test.data.table.R index 574bcb4f31..574d398a2e 100644 --- a/R/test.data.table.R +++ b/R/test.data.table.R @@ -225,10 +225,12 @@ test.data.table = function(script="tests.Rraw", verbose=FALSE, pkg=".", silent=F # does show the full file output these days, so the 13 line limit no longer bites so much. It still bit recently # when receiving output of R CMD check sent over email, though. tz = Sys.getenv("TZ", unset=NA) + + maybe_unknown = function(x) if (length(x)) x else "" cat("\n", date(), # so we can tell exactly when these tests ran on CRAN to double-check the result is up to date " endian==", .Platform$endian, - ", sizeof(long double)==", .Machine$sizeof.longdouble, - ", longdouble.digits==", .Machine$longdouble.digits, # 64 normally, 53 for example under valgrind where some high accuracy tests need turning off, #4639 + ", sizeof(long double)==", maybe_unknown(.Machine$sizeof.longdouble), + ", longdouble.digits==", maybe_unknown(.Machine$longdouble.digits), # 64 normally, 53 for example under valgrind where some high accuracy tests need turning off, #4639 ", sizeof(pointer)==", .Machine$sizeof.pointer, ", TZ==", if (is.na(tz)) "unset" else paste0("'",tz,"'"), ", Sys.timezone()=='", suppressWarnings(Sys.timezone()), "'", From 2eeb415d0a6aa5b33e02a649fca69a5a5c49438e Mon Sep 17 00:00:00 2001 From: Michael Chirico Date: Mon, 27 May 2024 16:49:02 -0700 Subject: [PATCH 2/3] Just use format() for simplicity --- R/test.data.table.R | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/R/test.data.table.R b/R/test.data.table.R index 574d398a2e..279bfc26eb 100644 --- a/R/test.data.table.R +++ b/R/test.data.table.R @@ -225,12 +225,10 @@ test.data.table = function(script="tests.Rraw", verbose=FALSE, pkg=".", silent=F # does show the full file output these days, so the 13 line limit no longer bites so much. It still bit recently # when receiving output of R CMD check sent over email, though. tz = Sys.getenv("TZ", unset=NA) - - maybe_unknown = function(x) if (length(x)) x else "" cat("\n", date(), # so we can tell exactly when these tests ran on CRAN to double-check the result is up to date " endian==", .Platform$endian, - ", sizeof(long double)==", maybe_unknown(.Machine$sizeof.longdouble), - ", longdouble.digits==", maybe_unknown(.Machine$longdouble.digits), # 64 normally, 53 for example under valgrind where some high accuracy tests need turning off, #4639 + ", sizeof(long double)==", format(.Machine$sizeof.longdouble), + ", longdouble.digits==", format(.Machine$longdouble.digits), # 64 normally, 53 for example under valgrind where some high accuracy tests need turning off, #4639 ", sizeof(pointer)==", .Machine$sizeof.pointer, ", TZ==", if (is.na(tz)) "unset" else paste0("'",tz,"'"), ", Sys.timezone()=='", suppressWarnings(Sys.timezone()), "'", From fd41733b14addcadf76bcc9f36e8a4340a77bc99 Mon Sep 17 00:00:00 2001 From: Michael Chirico Date: Fri, 27 Jun 2025 10:15:29 -0700 Subject: [PATCH 3/3] add capabilities, why not --- R/test.data.table.R | 1 + 1 file changed, 1 insertion(+) diff --git a/R/test.data.table.R b/R/test.data.table.R index 279bfc26eb..2f60cd282d 100644 --- a/R/test.data.table.R +++ b/R/test.data.table.R @@ -228,6 +228,7 @@ test.data.table = function(script="tests.Rraw", verbose=FALSE, pkg=".", silent=F cat("\n", date(), # so we can tell exactly when these tests ran on CRAN to double-check the result is up to date " endian==", .Platform$endian, ", sizeof(long double)==", format(.Machine$sizeof.longdouble), + ", capabilities('long.double')==", capabilities('long.double'), # almost certainly overkill, but that's OK; see #6154 ", longdouble.digits==", format(.Machine$longdouble.digits), # 64 normally, 53 for example under valgrind where some high accuracy tests need turning off, #4639 ", sizeof(pointer)==", .Machine$sizeof.pointer, ", TZ==", if (is.na(tz)) "unset" else paste0("'",tz,"'"),