R Under development (unstable) (2025-02-18 r87748 ucrt) -- "Unsuffered Consequences" Copyright (C) 2025 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > library(flint) > > x. <- as.integer(cumprod(1:11)) > for (.cl in c("ulong", "slong", "fmpz", "fmpq", "mag", "arf", "acf", + "arb", "acb")) { + x <- new(.cl, x = x.) + s <- structure(flintTriple(x), + names = c("class", "length", "address"), + class = "noquote") + ## summary + stopifnot(identical(summary(x, triple = TRUE), s)) + if (any(.cl == c("arb", "acb", "acf"))) + stopifnot(identical(summary(x), s)) + else + stopifnot(all.equal(summary(x), summary(x.), check.class = FALSE)) + ## quantile + if (any(.cl == c("arb", "acb"))) + stopifnot(tryCatch(as.null(quantile(x)), + notTotalOrderError = function (e) TRUE)) + else + for (.qt in 1:9) + stopifnot(all.equal(quantile(x , type = .qt), + quantile(x., type = .qt, names = FALSE), + check.class = FALSE)) + ## mean + stopifnot(all.equal(mean(x), mean(x.), check.class = FALSE)) + } > > proc.time() user system elapsed 1.92 0.17 2.37