From d1b7af0c2e097345f9a42acefe9aa6c85d2dfb18 Mon Sep 17 00:00:00 2001 From: Tyson Barrett Date: Wed, 24 Dec 2025 12:51:53 -0700 Subject: [PATCH 1/2] 1.18.0 on CRAN. Bump to 1.18.99 --- DESCRIPTION | 2 +- NEWS.md | 2 +- po/R-data.table.pot | 298 ++++++++++++++-------------- po/data.table.pot | 468 +++++++++++++++++++------------------------- src/init.c | 2 +- 5 files changed, 350 insertions(+), 422 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 966865afe..ab359df08 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,5 +1,5 @@ Package: data.table -Version: 1.17.99 +Version: 1.18.0 Title: Extension of `data.frame` Depends: R (>= 3.4.0) Imports: methods diff --git a/NEWS.md b/NEWS.md index 1c8540a9c..aed1752d8 100644 --- a/NEWS.md +++ b/NEWS.md @@ -2,7 +2,7 @@ **If you are viewing this file on CRAN, please check [latest news on GitHub](https://github.com/Rdatatable/data.table/blob/master/NEWS.md) where the formatting is also better.** -## data.table [v1.17.99](https://github.com/Rdatatable/data.table/milestone/35) (in development) +## data.table [v1.18.0](https://github.com/Rdatatable/data.table/milestone/37?closed=1) 23 December 2025 ### BREAKING CHANGE diff --git a/po/R-data.table.pot b/po/R-data.table.pot index a27ccad52..960681dd7 100644 --- a/po/R-data.table.pot +++ b/po/R-data.table.pot @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: data.table 1.17.99\n" -"POT-Creation-Date: 2025-12-13 17:01+0000\n" +"POT-Creation-Date: 2025-12-23 12:03-0700\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -65,30 +65,30 @@ msgstr "" msgid "Please provide either 'key' or 'sorted', but not both." msgstr "" -#: as.data.table.R:111 +#: as.data.table.R:112 #, c-format msgid "" "Argument 'value.name' should not overlap with column names in result: %s" msgstr "" -#: as.data.table.R:161 +#: as.data.table.R:162 #, c-format msgid "" "POSIXlt column type detected and converted to POSIXct. We do not recommend " "use of POSIXlt at all because it uses 40 bytes to store one date." msgstr "" -#: as.data.table.R:206 +#: as.data.table.R:207 #, c-format msgid "Item %d has %d rows but longest item has %d; recycled with remainder." msgstr "" -#: as.data.table.R:221 +#: as.data.table.R:222 #, c-format msgid "A column may not be called .SD. That has special meaning." msgstr "" -#: as.data.table.R:247 +#: as.data.table.R:248 #, c-format msgid "class must be length 1" msgstr "" @@ -833,13 +833,13 @@ msgid "" "'numeric')" msgstr "" -#: data.table.R:1209 +#: data.table.R:1210 msgid "" "No rows match i. No new columns to add so not evaluating RHS of :=\n" "Assigning to 0 row subset of %d rows" msgstr "" -#: data.table.R:1225 +#: data.table.R:1226 #, c-format msgid "" "A shallow copy of this data.table was taken so that := can add or remove %d " @@ -853,23 +853,7 @@ msgid "" "improved." msgstr "" -#: data.table.R:1285 -#, c-format -msgid "" -"Variable '%s' is not found in calling scope. Looking in calling scope " -"because this symbol was prefixed with .. in the j= parameter." -msgstr "" - -#: data.table.R:1358 -#, c-format -msgid "" -"j (the 2nd argument inside [...]) is a single symbol but column name '%1$s' " -"is not found. If you intended to select columns using a variable in calling " -"scope, please try DT[, ..%1$s]. The .. prefix conveys one-level-up similar " -"to a file system path." -msgstr "" - -#: data.table.R:1408 +#: data.table.R:1246 msgid "" "Growing vector of column pointers from truelength %d to %d. A shallow copy " "has been taken, see ?setalloccol. Only a potential issue if two variables " @@ -879,77 +863,93 @@ msgid "" "'datatable.alloccol' option." msgstr "" -#: data.table.R:1410 +#: data.table.R:1248 msgid "" "Note that the shallow copy will assign to the environment from which := was " "called. That means for example that if := was called within a function, the " "original table may be unaffected." msgstr "" -#: data.table.R:1495 +#: data.table.R:1326 +#, c-format +msgid "" +"Variable '%s' is not found in calling scope. Looking in calling scope " +"because this symbol was prefixed with .. in the j= parameter." +msgstr "" + +#: data.table.R:1399 +#, c-format +msgid "" +"j (the 2nd argument inside [...]) is a single symbol but column name '%1$s' " +"is not found. If you intended to select columns using a variable in calling " +"scope, please try DT[, ..%1$s]. The .. prefix conveys one-level-up similar " +"to a file system path." +msgstr "" + +#: data.table.R:1512 #, c-format msgid "" "The column '.N' can't be grouped because it conflicts with the special .N " "variable. Try setnames(DT,'.N','N') first." msgstr "" -#: data.table.R:1496 +#: data.table.R:1513 #, c-format msgid "" "The column '.I' can't be grouped because it conflicts with the special .I " "variable. Try setnames(DT,'.I','I') first." msgstr "" -#: data.table.R:1515 +#: data.table.R:1532 msgid "" "Note: forcing units=\"secs\" on implicit difftime by group; call difftime " "explicitly to choose custom units" msgstr "" -#: data.table.R:1524 +#: data.table.R:1541 #, c-format msgid "logical error. i is not a data.table, but mult='all' and 'by'=.EACHI" msgstr "" -#: data.table.R:1551 +#: data.table.R:1568 msgid "Finding groups using forderv ..." msgstr "" -#: data.table.R:1565 data.table.R:1597 +#: data.table.R:1582 data.table.R:1614 msgid "Finding group sizes from the positions (can be avoided to save RAM) ..." msgstr "" -#: data.table.R:1573 +#: data.table.R:1590 msgid "Getting back original order ..." msgstr "" -#: data.table.R:1585 +#: data.table.R:1602 msgid "Finding groups using uniqlist on key ..." msgstr "" -#: data.table.R:1589 +#: data.table.R:1606 msgid "Finding groups using uniqlist on index '%s' ..." msgstr "" -#: data.table.R:1808 +#: data.table.R:1825 msgid "lapply optimization changed j from '%s' to '%s'" msgstr "" -#: data.table.R:1810 +#: data.table.R:1827 msgid "lapply optimization is on, j unchanged as '%s'" msgstr "" -#: data.table.R:1819 data.table.R:1843 +#: data.table.R:1836 data.table.R:1860 msgid "GForce optimized j to '%s' (see ?GForce)" msgstr "" -#: data.table.R:1844 +#: data.table.R:1861 msgid "" "GForce is on, but not activated for this query; left j unchanged (see ?" "GForce)" msgstr "" -#: data.table.R:1863 +#: data.table.R:1880 #, c-format msgid "" "Unable to optimize call to mean() and could be very slow. You must name 'na." @@ -957,31 +957,31 @@ msgid "" "'trim' which is the 2nd argument of mean. 'trim' is not yet optimized." msgstr "" -#: data.table.R:1867 +#: data.table.R:1884 msgid "Old mean optimization changed j from '%s' to '%s'" msgstr "" -#: data.table.R:1869 +#: data.table.R:1886 msgid "Old mean optimization is on, left j unchanged." msgstr "" -#: data.table.R:1879 +#: data.table.R:1896 msgid "All optimizations are turned off" msgstr "" -#: data.table.R:1880 +#: data.table.R:1897 msgid "Optimization is on but left j unchanged (single plain symbol): '%s'" msgstr "" -#: data.table.R:1909 +#: data.table.R:1926 msgid "Making each group and running j (GForce %s) ..." msgstr "" -#: data.table.R:2005 +#: data.table.R:2022 msgid "setkey() after the := with keyby= ..." msgstr "" -#: data.table.R:2009 +#: data.table.R:2026 #, c-format msgid "" "The setkey() normally performed by keyby= has been skipped (as if by= was " @@ -990,81 +990,81 @@ msgid "" "existing column names to keyby=." msgstr "" -#: data.table.R:2035 +#: data.table.R:2052 msgid "setkey() afterwards for keyby=.EACHI ..." msgstr "" -#: data.table.R:2144 +#: data.table.R:2161 #, c-format msgid "rownames and rownames.value cannot both be used at the same time" msgstr "" -#: data.table.R:2147 +#: data.table.R:2164 #, c-format msgid "" "length(rownames)==%d but nrow(DT)==%d. The rownames argument specifies a " "single column name or number. Consider rownames.value= instead." msgstr "" -#: data.table.R:2151 +#: data.table.R:2168 #, c-format msgid "" "length(rownames)==0 but should be a single column name or number, or NULL" msgstr "" -#: data.table.R:2155 +#: data.table.R:2172 #, c-format msgid "" "rownames is TRUE but key has multiple columns %s; taking first column x[,1] " "as rownames" msgstr "" -#: data.table.R:2165 +#: data.table.R:2182 #, c-format msgid "'%s' is not a column of x" msgstr "" -#: data.table.R:2171 +#: data.table.R:2188 #, c-format msgid "" "as.integer(rownames)==%d which is outside the column number range [1,ncol=" "%d]." msgstr "" -#: data.table.R:2176 +#: data.table.R:2193 #, c-format msgid "length(rownames.value)==%d but should be nrow(x)==%d" msgstr "" -#: data.table.R:2272 +#: data.table.R:2289 #, c-format msgid "" "When i is a matrix in DT[i]<-value syntax, it doesn't make sense to provide j" msgstr "" -#: data.table.R:2282 +#: data.table.R:2299 #, c-format msgid "j must be an atomic vector, see ?is.atomic" msgstr "" -#: data.table.R:2283 +#: data.table.R:2300 #, c-format msgid "NA in j" msgstr "" -#: data.table.R:2289 +#: data.table.R:2306 #, c-format msgid "j must be vector of column name or positions" msgstr "" -#: data.table.R:2290 +#: data.table.R:2307 #, c-format msgid "" "Attempt to assign to column position greater than ncol(x). Create the column " "by name, instead. This logic intends to catch (most likely) user errors." msgstr "" -#: data.table.R:2357 +#: data.table.R:2374 #, c-format msgid "" "data.table inherits from data.frame (from v1.5), but this data.table does " @@ -1072,87 +1072,87 @@ msgid "" "'data.table') or saved to disk using a prior version of data.table?" msgstr "" -#: data.table.R:2366 +#: data.table.R:2383 #, c-format msgid "attempting to assign invalid object to dimnames of a data.table" msgstr "" -#: data.table.R:2367 +#: data.table.R:2384 #, c-format msgid "data.tables do not have rownames" msgstr "" -#: data.table.R:2368 data.table.R:2752 +#: data.table.R:2385 data.table.R:2769 #, c-format msgid "Can't assign %d names to a %d-column data.table" msgstr "" -#: data.table.R:2432 +#: data.table.R:2449 #, c-format msgid "'subset' must evaluate to logical" msgstr "" -#: data.table.R:2475 +#: data.table.R:2492 #, c-format msgid "Argument 'invert' must be logical TRUE/FALSE" msgstr "" -#: data.table.R:2521 +#: data.table.R:2538 #, c-format msgid "group length is 0 but data nrow > 0" msgstr "" -#: data.table.R:2523 +#: data.table.R:2540 #, c-format msgid "" "passing 'f' argument together with 'by' is not allowed, use 'by' when split " "by column in data.table and 'f' when split by external factor" msgstr "" -#: data.table.R:2531 +#: data.table.R:2548 #, c-format msgid "Either 'by' or 'f' argument must be supplied" msgstr "" -#: data.table.R:2533 +#: data.table.R:2550 #, c-format msgid "Column '.ll.tech.split' is reserved for split.data.table processing" msgstr "" -#: data.table.R:2534 +#: data.table.R:2551 #, c-format msgid "Column '.nm.tech.split' is reserved for split.data.table processing" msgstr "" -#: data.table.R:2535 +#: data.table.R:2552 #, c-format msgid "Argument 'by' must refer to column names in x" msgstr "" -#: data.table.R:2536 +#: data.table.R:2553 #, c-format msgid "" "Argument 'by' must refer only to atomic-type columns, but the following " "columns are non-atomic: %s" msgstr "" -#: data.table.R:2583 +#: data.table.R:2600 msgid "Processing split.data.table with: %s" msgstr "" -#: data.table.R:2683 +#: data.table.R:2700 #, c-format msgid "" "x is not a data.table|frame. Shallow copy is a copy of the vector of column " "pointers (only), so is only meaningful for data.table|frame" msgstr "" -#: data.table.R:2692 +#: data.table.R:2709 #, c-format msgid "setalloccol attempting to modify `*tmp*`" msgstr "" -#: data.table.R:2727 +#: data.table.R:2744 #, c-format msgid "" "Input is a length=1 logical that points to the same address as R's global " @@ -1160,52 +1160,52 @@ msgid "" "copy. You will need to assign the result back to a variable. See issue #1281." msgstr "" -#: data.table.R:2742 +#: data.table.R:2759 #, c-format msgid "x is not a data.table or data.frame" msgstr "" -#: data.table.R:2744 +#: data.table.R:2761 #, c-format msgid "x has %d columns but its names are length %d" msgstr "" -#: data.table.R:2751 +#: data.table.R:2768 #, c-format msgid "Passed a vector of type '%s'. Needs to be type 'character'." msgstr "" -#: data.table.R:2764 +#: data.table.R:2781 #, c-format msgid "'new' is not a character vector or a function" msgstr "" -#: data.table.R:2766 +#: data.table.R:2783 #, c-format msgid "NA in 'new' at positions %s" msgstr "" -#: data.table.R:2767 +#: data.table.R:2784 #, c-format msgid "Some duplicates exist in 'old': %s" msgstr "" -#: data.table.R:2769 +#: data.table.R:2786 #, c-format msgid "'old' is type %s but should be integer, double or character" msgstr "" -#: data.table.R:2770 +#: data.table.R:2787 #, c-format msgid "'old' is length %d but 'new' is length %d" msgstr "" -#: data.table.R:2771 +#: data.table.R:2788 #, c-format msgid "NA (or out of bounds) in 'old' at positions %s" msgstr "" -#: data.table.R:2774 +#: data.table.R:2791 #, c-format msgid "" "Item %d of 'old' is '%s' which appears several times in column names. Just " @@ -1213,40 +1213,40 @@ msgid "" "duplicated in column names." msgstr "" -#: data.table.R:2782 +#: data.table.R:2799 #, c-format msgid "" "Items of 'old' not found in column names: %s. Consider skip_absent=TRUE." msgstr "" -#: data.table.R:2823 +#: data.table.R:2840 #, c-format msgid "Provide either before= or after= but not both" msgstr "" -#: data.table.R:2825 +#: data.table.R:2842 #, c-format msgid "before=/after= accept a single column name or number, not more than one" msgstr "" -#: data.table.R:2882 +#: data.table.R:2910 #, c-format msgid "Input is %s but should be a plain list of items to be stacked" msgstr "" -#: data.table.R:2886 +#: data.table.R:2914 #, c-format msgid "" "idcol must be a logical or character vector of length 1. If logical TRUE the " "id column will named '.id'." msgstr "" -#: data.table.R:2891 +#: data.table.R:2919 #, c-format msgid "use.names=NA invalid" msgstr "" -#: data.table.R:2893 +#: data.table.R:2921 #, c-format msgid "" "use.names='check' cannot be used explicitly because the value 'check' is new " @@ -1254,7 +1254,7 @@ msgid "" "behavior. See ?rbindlist." msgstr "" -#: data.table.R:2908 +#: data.table.R:2936 #, c-format msgid "" "Check that is.data.table(DT) == TRUE. Otherwise, `:=` is defined for use in " @@ -1265,33 +1265,33 @@ msgid "" "=` as the only statement in `j`." msgstr "" -#: data.table.R:2925 +#: data.table.R:2953 #, c-format msgid "" "setDF only accepts data.table, data.frame or list of equal length as input" msgstr "" -#: data.table.R:2926 +#: data.table.R:2954 #, c-format msgid "rownames contains duplicates" msgstr "" -#: data.table.R:2933 data.table.R:2944 data.table.R:2967 +#: data.table.R:2961 data.table.R:2972 data.table.R:2995 #, c-format msgid "rownames incorrect length; expected %d names, got %d" msgstr "" -#: data.table.R:2952 +#: data.table.R:2980 #, c-format msgid "All elements in argument 'x' to 'setDF' must be of same length" msgstr "" -#: data.table.R:2981 +#: data.table.R:3009 #, c-format msgid "Cannot find symbol %s" msgstr "" -#: data.table.R:2988 +#: data.table.R:3016 #, c-format msgid "" "Cannot convert '%1$s' to data.table by reference because binding is locked. " @@ -1301,92 +1301,92 @@ msgid "" "setDT again." msgstr "" -#: data.table.R:3042 +#: data.table.R:3070 #, c-format msgid "" "Argument 'x' to 'setDT' should be a 'list', 'data.frame' or 'data.table'" msgstr "" -#: data.table.R:3075 data.table.R:3100 +#: data.table.R:3103 data.table.R:3128 #, c-format msgid "'prefix' must be NULL or a character vector of length 1." msgstr "" -#: data.table.R:3078 data.table.R:3103 +#: data.table.R:3106 data.table.R:3131 #, c-format msgid "x is a single vector, non-NULL 'cols' doesn't make sense." msgstr "" -#: data.table.R:3082 data.table.R:3107 +#: data.table.R:3110 data.table.R:3135 #, c-format msgid "x is a list, 'cols' cannot be 0-length." msgstr "" -#: data.table.R:3262 +#: data.table.R:3290 #, c-format msgid "" "It looks like you re-used `:=` in argument %d a functional assignment " "call -- use `=` instead: %s(col1=val1, col2=val2, ...)" msgstr "" -#: data.table.R:3328 +#: data.table.R:3356 #, c-format msgid "" "RHS of %s is length %d which is not 1 or nrow (%d). For robustness, no " "recycling is allowed (other than of length 1 RHS). Consider %%in%% instead." msgstr "" -#: data.table.R:3360 +#: data.table.R:3388 msgid "" "Subsetting optimization disabled because the cross-product of RHS values " "exceeds 1e4, causing memory problems." msgstr "" -#: data.table.R:3378 +#: data.table.R:3406 msgid "Optimized subsetting with key %s" msgstr "" -#: data.table.R:3397 data.table.R:3409 +#: data.table.R:3425 data.table.R:3437 msgid "Optimized subsetting with index '%s'" msgstr "" -#: data.table.R:3404 +#: data.table.R:3432 msgid "Creating new index '%s'" msgstr "" -#: data.table.R:3405 +#: data.table.R:3433 msgid "Creating index %s done in ..." msgstr "" -#: data.table.R:3438 +#: data.table.R:3466 #, c-format msgid "" "'on' argument should be a named atomic vector of column names indicating " "which columns in 'i' should be joined with which columns in 'x'." msgstr "" -#: data.table.R:3479 +#: data.table.R:3507 #, c-format msgid "" "Found more than one operator in one 'on' statement: %s. Please specify a " "single operator." msgstr "" -#: data.table.R:3502 +#: data.table.R:3530 #, c-format msgid "" "'on' contains no column name: %s. Each 'on' clause must contain one or two " "column names." msgstr "" -#: data.table.R:3504 +#: data.table.R:3532 #, c-format msgid "" "'on' contains more than 2 column names: %s. Each 'on' clause must contain " "one or two column names." msgstr "" -#: data.table.R:3509 +#: data.table.R:3537 #, c-format msgid "Invalid join operators %s. Only allowed operators are %s." msgstr "" @@ -3485,7 +3485,7 @@ msgid "" "too, please restart R with LANGUAGE=en" msgstr "" -#: test.data.table.R:148 +#: test.data.table.R:149 msgid "" "***\n" "*** memtest=%d. This should be the first call in a fresh R_GC_MEM_GROW=0 R " @@ -3493,129 +3493,133 @@ msgid "" "***" msgstr "" -#: test.data.table.R:149 +#: test.data.table.R:150 #, c-format msgid "" "memtest intended for Linux. Step through data.table:::rss() to see what went " "wrong." msgstr "" -#: test.data.table.R:203 +#: test.data.table.R:204 #, c-format msgid "Attempt to subset to %d tests matching '%s' failed, running full suite." msgstr "" -#: test.data.table.R:208 +#: test.data.table.R:209 msgid "Running %d of %d tests matching '%s'" msgstr "" -#: test.data.table.R:278 +#: test.data.table.R:279 #, c-format msgid "Failed in %s after test %s before the next test() call in %s" msgstr "" -#: test.data.table.R:306 +#: test.data.table.R:308 #, c-format msgid "" "Tests succeeded, but non-test code caused warnings. Search %s for tests " "shown above." msgstr "" -#: test.data.table.R:316 +#: test.data.table.R:318 #, c-format msgid "Timings count mismatch: %d vs %d" msgstr "" -#: test.data.table.R:318 +#: test.data.table.R:320 msgid "10 longest running tests took %ds (%d%% of %ds)" msgstr "" -#: test.data.table.R:324 +#: test.data.table.R:326 msgid "10 largest RAM increases (MiB); see plot for cumulative effect (if any)" msgstr "" -#: test.data.table.R:334 +#: test.data.table.R:336 +msgid "Skipped %d tests for translated messages." +msgstr "" + +#: test.data.table.R:337 msgid "All %d tests (last %.8g) in %s completed ok in %s" msgstr "" -#: test.data.table.R:430 +#: test.data.table.R:434 msgid "Running test id %s" msgstr "" -#: test.data.table.R:448 +#: test.data.table.R:452 #, c-format msgid "" "Test %s is invalid: when error= is provided it does not make sense to pass y " "as well" msgstr "" -#: test.data.table.R:493 +#: test.data.table.R:506 msgid "Test id %s is not in increasing order" msgstr "" -#: test.data.table.R:510 +#: test.data.table.R:523 msgid "" "Test %s produced %d %ss but expected %d\n" "%s\n" "%s" msgstr "" -#: test.data.table.R:518 +#: test.data.table.R:531 msgid "" "Test %s didn't produce the correct %s:\n" "Expected: %s\n" "Observed: %s" msgstr "" -#: test.data.table.R:527 +#: test.data.table.R:540 msgid "Output captured before unexpected warning/error/message:" msgstr "" -#: test.data.table.R:538 +#: test.data.table.R:551 msgid "Test %s did not produce correct output:" msgstr "" -#: test.data.table.R:539 +#: test.data.table.R:552 msgid "Expected: <<%s>>" msgstr "" -#: test.data.table.R:540 test.data.table.R:552 +#: test.data.table.R:553 test.data.table.R:565 msgid "Observed: <<%s>>" msgstr "" -#: test.data.table.R:542 +#: test.data.table.R:555 msgid "Expected (raw): <<%s>>" msgstr "" -#: test.data.table.R:543 test.data.table.R:555 +#: test.data.table.R:556 test.data.table.R:568 msgid "Observed (raw): <<%s>>" msgstr "" -#: test.data.table.R:550 +#: test.data.table.R:563 msgid "Test %s produced output but should not have:" msgstr "" -#: test.data.table.R:551 +#: test.data.table.R:564 msgid "Expected absent (case insensitive): <<%s>>" msgstr "" -#: test.data.table.R:554 +#: test.data.table.R:567 msgid "Expected absent (raw): <<%s>>" msgstr "" -#: test.data.table.R:570 +#: test.data.table.R:583 msgid "Test %s ran without errors but selfrefok(%s) is FALSE" msgstr "" -#: test.data.table.R:595 +#: test.data.table.R:608 msgid "Test %s ran without errors but failed check that x equals y:" msgstr "" -#: test.data.table.R:600 +#: test.data.table.R:613 msgid "First %d of %d (type '%s'):" msgstr "" -#: test.data.table.R:605 +#: test.data.table.R:618 msgid "Non-ASCII string detected, raw representation:" msgstr "" @@ -3843,13 +3847,13 @@ msgid_plural "unsupported column types found in x or y: %s" msgstr[0] "" msgstr[1] "" -#: test.data.table.R:288 +#: test.data.table.R:290 msgid "%d error out of %d. Search %s for test number %s. Duration: %s." msgid_plural "%d errors out of %d. Search %s for test numbers %s. Duration: %s." msgstr[0] "" msgstr[1] "" -#: test.data.table.R:298 +#: test.data.table.R:300 msgid "Caught %d warning outside the test() calls:\n" msgid_plural "Caught %d warnings outside the test() calls:\n" msgstr[0] "" diff --git a/po/data.table.pot b/po/data.table.pot index 9553941a6..d4fb8b49e 100644 --- a/po/data.table.pot +++ b/po/data.table.pot @@ -1,7 +1,7 @@ msgid "" msgstr "" "Project-Id-Version: data.table 1.17.99\n" -"POT-Creation-Date: 2025-12-13 17:01+0000\n" +"POT-Creation-Date: 2025-12-23 12:03-0700\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -98,7 +98,7 @@ msgstr "" msgid "getOption('datatable.alloccol')==%d. It must be >=0 and not NA." msgstr "" -#: assign.c:225 between.c:22 between.c:28 frollR.c:97 frollR.c:112 fsort.c:117 gsumm.c:351 gsumm.c:587 gsumm.c:733 gsumm.c:871 gsumm.c:1026 gsumm.c:1118 nafill.c:108 openmp-utils.c:97 uniqlist.c:358 utils.c:118 utils.c:120 +#: assign.c:225 between.c:22 between.c:28 frollR.c:97 frollR.c:112 fsort.c:117 gsumm.c:351 gsumm.c:587 gsumm.c:733 gsumm.c:871 gsumm.c:1026 gsumm.c:1118 nafill.c:108 openmp-utils.c:97 uniqlist.c:358 utils.c:122 utils.c:124 #, c-format msgid "%s must be TRUE or FALSE" msgstr "" @@ -152,11 +152,6 @@ msgstr "" msgid "Assigning to %d row subset of %d rows\n" msgstr "" -#: assign.c:326 -#, c-format -msgid "Added %d new column initialized with all-NA\n" -msgstr "" - #: assign.c:332 msgid "length(LHS)==0; no columns to delete or assign RHS to." msgstr "" @@ -398,171 +393,152 @@ msgid "" "character, NA in any type, or level numbers." msgstr "" -#: assign.c:813 -msgid "Unable to allocate working memory of %zu bytes to combine factor levels" -msgstr "" - -#: assign.c:840 +#: assign.c:822 #, c-format msgid "Coercing 'character' RHS to '%s' to match the type of target vector." msgstr "" -#: assign.c:842 +#: assign.c:824 #, c-format msgid "" "Coercing 'character' RHS to '%s' to match the type of column %d named '%s'." msgstr "" -#: assign.c:850 +#: assign.c:832 msgid "" "Cannot coerce 'list' RHS to 'integer64' to match the type of target vector." msgstr "" -#: assign.c:852 +#: assign.c:834 #, c-format msgid "" "Cannot coerce 'list' RHS to 'integer64' to match the type of column %d named " "'%s'." msgstr "" -#: assign.c:858 +#: assign.c:840 #, c-format msgid "Coercing 'list' RHS to '%s' to match the type of target vector." msgstr "" -#: assign.c:860 +#: assign.c:842 #, c-format msgid "Coercing 'list' RHS to '%s' to match the type of column %d named '%s'." msgstr "" -#: assign.c:868 +#: assign.c:850 #, c-format msgid "Zero-copy coerce when assigning '%s' to '%s' target vector.\n" msgstr "" -#: assign.c:870 +#: assign.c:852 #, c-format msgid "" "Zero-copy coerce when assigning '%s' to column %d named '%s' which is '%s'.\n" msgstr "" -#: assign.c:886 +#: assign.c:868 #, c-format msgid "(target vector)" msgstr "" -#: assign.c:896 assign.c:897 +#: assign.c:878 assign.c:879 #, c-format msgid "" "%d (type '%s') at RHS position %d taken as TRUE when assigning to type '%s' " "%s" msgstr "" -#: assign.c:899 +#: assign.c:881 #, c-format msgid "" "% (type '%s') at RHS position %d taken as TRUE when assigning to " "type '%s' %s" msgstr "" -#: assign.c:900 +#: assign.c:882 #, c-format msgid "" "%f (type '%s') at RHS position %d taken as TRUE when assigning to type '%s' " "%s" msgstr "" -#: assign.c:904 +#: assign.c:886 #, c-format msgid "" "%d (type '%s') at RHS position %d taken as 0 when assigning to type '%s' %s" msgstr "" -#: assign.c:906 +#: assign.c:888 #, c-format msgid "" "% (type '%s') at RHS position %d taken as 0 when assigning to type " "'%s' %s" msgstr "" -#: assign.c:907 +#: assign.c:889 #, c-format msgid "" "%f (type '%s') at RHS position %d either truncated (precision lost) or taken " "as 0 when assigning to type '%s' %s" msgstr "" -#: assign.c:912 +#: assign.c:894 #, c-format msgid "" "% (type '%s') at RHS position %d out-of-range (NA) when assigning to " "type '%s' %s" msgstr "" -#: assign.c:913 assign.c:920 +#: assign.c:895 assign.c:902 #, c-format msgid "" "%f (type '%s') at RHS position %d out-of-range(NA) or truncated (precision " "lost) when assigning to type '%s' %s" msgstr "" -#: assign.c:915 assign.c:924 +#: assign.c:897 assign.c:906 #, c-format msgid "" "%f (type '%s') at RHS position %d either imaginary part discarded or real " "part truncated (precision lost) when assigning to type '%s' %s" msgstr "" -#: assign.c:925 +#: assign.c:907 #, c-format msgid "" "%f (type '%s') at RHS position %d imaginary part discarded when assigning to " "type '%s' %s" msgstr "" -#: assign.c:970 +#: assign.c:952 #, c-format msgid "type '%s' cannot be coerced to '%s'" msgstr "" -#: assign.c:1128 +#: assign.c:1110 #, c-format msgid "Unsupported column type in assign.c:memrecycle '%s'" msgstr "" -#: assign.c:1222 -#, c-format -msgid "Failed to allocate initial %d items in savetl_init" -msgstr "" - -#: assign.c:1238 -#, c-format -msgid "Failed to realloc saveds to %d items in savetl" -msgstr "" - -#: assign.c:1244 -#, c-format -msgid "Failed to realloc savedtl to %d items in savetl" -msgstr "" - -#: assign.c:1267 +#: assign.c:1193 msgid "x must be a character vector" msgstr "" -#: assign.c:1268 +#: assign.c:1194 msgid "'which' must be an integer vector" msgstr "" -#: assign.c:1269 +#: assign.c:1195 msgid "'new' must be a character vector" msgstr "" -#: assign.c:1270 +#: assign.c:1196 #, c-format msgid "'new' is length %d. Should be the same as length of 'which' (%d)" msgstr "" -#: assign.c:1273 +#: assign.c:1199 #, c-format msgid "" "Item %d of 'which' is %d which is outside range of the length %d character " @@ -677,13 +653,6 @@ msgstr "" msgid "x is type '%s' (must be 'character' or NULL)" msgstr "" -#: chmatch.c:106 -#, c-format -msgid "" -"Failed to allocate % bytes working memory in chmatchdup: " -"length(table)=%d length(unique(table))=%d" -msgstr "" - #: cj.c:95 #, c-format msgid "Type '%s' is not supported by CJ." @@ -748,33 +717,33 @@ msgstr "" msgid "env is not an environment" msgstr "" -#: dogroups.c:133 +#: dogroups.c:136 msgid "row.names attribute of .SD not found" msgstr "" -#: dogroups.c:135 +#: dogroups.c:138 #, c-format msgid "" "row.names of .SD isn't integer length 2 with NA as first item; i.e., ." "set_row_names(). [%s %d %d]" msgstr "" -#: dogroups.c:166 +#: dogroups.c:169 #, c-format msgid "length(iSD)[%d] != length(jiscols)[%d]" msgstr "" -#: dogroups.c:167 +#: dogroups.c:170 #, c-format msgid "length(xSD)[%d] != length(xjiscols)[%d]" msgstr "" -#: dogroups.c:279 +#: dogroups.c:282 #, c-format msgid "j evaluates to type '%s'. Must evaluate to atomic vector or list." msgstr "" -#: dogroups.c:288 +#: dogroups.c:291 #, c-format msgid "" "Entry %d for group %d in j=list(...) should be atomic vector or list. If you " @@ -782,7 +751,7 @@ msgid "" "instead (much quicker), or cbind or merge afterwards." msgstr "" -#: dogroups.c:295 +#: dogroups.c:298 #, c-format msgid "" "Entry %d for group %d in j=list(...) is an array with %d dimensions > 1, " @@ -790,13 +759,13 @@ msgid "" "that is intentional." msgstr "" -#: dogroups.c:305 +#: dogroups.c:308 msgid "" "RHS of := is NULL during grouped assignment, but it's not possible to delete " "parts of a column." msgstr "" -#: dogroups.c:309 +#: dogroups.c:312 #, c-format msgid "" "Supplied %d items to be assigned to group %d of size %d in column '%s'. The " @@ -805,16 +774,16 @@ msgid "" "make this intent clear to readers of your code." msgstr "" -#: dogroups.c:342 +#: dogroups.c:345 #, c-format msgid "Group %d column '%s': %s" msgstr "" -#: dogroups.c:349 +#: dogroups.c:352 msgid "j doesn't evaluate to the same number of columns for each group" msgstr "" -#: dogroups.c:383 +#: dogroups.c:386 #, c-format msgid "" "Column %d of j's result for the first group is NULL. We rely on the column " @@ -825,14 +794,14 @@ msgid "" "integer() or numeric()." msgstr "" -#: dogroups.c:386 +#: dogroups.c:389 msgid "" "j appears to be a named vector. The same names will likely be created over " "and over again for each group and slow things down. Try and pass a named " "list (which data.table optimizes) or an unnamed list() instead.\n" msgstr "" -#: dogroups.c:388 +#: dogroups.c:391 #, c-format msgid "" "Column %d of j is a named vector (each item down the rows is named, " @@ -840,7 +809,7 @@ msgid "" "over and over for each group). They are ignored anyway.\n" msgstr "" -#: dogroups.c:396 +#: dogroups.c:399 msgid "" "The result of j is a named list. It's very inefficient to create the same " "names over and over again for each group. When j=list(...), any names are " @@ -849,12 +818,12 @@ msgid "" "to :=). This message may be upgraded to warning in future.\n" msgstr "" -#: dogroups.c:408 +#: dogroups.c:411 #, c-format msgid "dogroups: growing from %d to %d rows\n" msgstr "" -#: dogroups.c:428 +#: dogroups.c:431 #, c-format msgid "" "Item %d of j's result for group %d is zero length. This will be filled with " @@ -863,14 +832,14 @@ msgid "" "buffer." msgstr "" -#: dogroups.c:435 +#: dogroups.c:438 #, c-format msgid "" "Column %d of result for group %d is type '%s' but expecting type '%s'. " "Column types must be consistent for each group." msgstr "" -#: dogroups.c:437 +#: dogroups.c:440 #, c-format msgid "" "Supplied %d items for column %d of group %d which has %d rows. The RHS " @@ -879,41 +848,41 @@ msgid "" "make this intent clear to readers of your code." msgstr "" -#: dogroups.c:456 fsort.c:264 fwrite.c:749 +#: dogroups.c:459 fsort.c:264 fwrite.c:749 msgid "\n" msgstr "" -#: dogroups.c:458 dogroups.c:475 +#: dogroups.c:461 dogroups.c:478 #, c-format msgid "" "Processed %d groups out of %d. %.0f%% done. Time elapsed: %ds. ETA: %ds." msgstr "" -#: dogroups.c:481 +#: dogroups.c:484 #, c-format msgid "Wrote less rows (%d) than allocated (%d).\n" msgstr "" -#: dogroups.c:505 +#: dogroups.c:493 #, c-format msgid "" "\n" " collecting discontiguous groups took %.3fs for %d groups\n" msgstr "" -#: dogroups.c:506 +#: dogroups.c:494 #, c-format msgid "" "\n" " memcpy contiguous groups took %.3fs for %d groups\n" msgstr "" -#: dogroups.c:508 +#: dogroups.c:496 #, c-format msgid " eval(j) took %.3fs for %d calls\n" msgstr "" -#: dogroups.c:522 +#: dogroups.c:510 msgid "growVector passed NULL" msgstr "" @@ -1194,7 +1163,7 @@ msgid "" "table" msgstr "" -#: fmelt.c:466 +#: fmelt.c:465 #, c-format msgid "" "'measure.vars' [%s] are not all of the same type. By order of hierarchy, the " @@ -1203,170 +1172,162 @@ msgid "" "coercion.\n" msgstr "" -#: fmelt.c:578 +#: fmelt.c:577 #, c-format msgid "Unknown column type '%s' for column '%s'." msgstr "" -#: fmelt.c:685 +#: fmelt.c:684 #, c-format msgid "variable_table does not support column type '%s' for column '%s'." msgstr "" -#: fmelt.c:779 +#: fmelt.c:778 #, c-format msgid "Unknown column type '%s' for column '%s' in 'data'" msgstr "" -#: fmelt.c:790 +#: fmelt.c:789 msgid "Input is not of type VECSXP, expected a data.table, data.frame or list" msgstr "" -#: fmelt.c:791 +#: fmelt.c:790 msgid "Argument 'value.factor' should be logical TRUE/FALSE" msgstr "" -#: fmelt.c:792 +#: fmelt.c:791 msgid "Argument 'variable.factor' should be logical TRUE/FALSE" msgstr "" -#: fmelt.c:793 +#: fmelt.c:792 msgid "Argument 'na.rm' should be logical TRUE/FALSE." msgstr "" -#: fmelt.c:794 +#: fmelt.c:793 msgid "Argument 'variable.name' must be a character vector" msgstr "" -#: fmelt.c:795 +#: fmelt.c:794 msgid "Argument 'value.name' must be a character vector" msgstr "" -#: fmelt.c:796 +#: fmelt.c:795 msgid "Argument 'verbose' should be logical TRUE/FALSE" msgstr "" -#: fmelt.c:800 +#: fmelt.c:799 msgid "ncol(data) is 0. Nothing to melt. Returning original data.table." msgstr "" -#: forder.c:112 utils.c:660 +#: forder.c:108 utils.c:652 msgid "Internal error in" msgstr "" -#: forder.c:112 utils.c:660 +#: forder.c:108 utils.c:652 msgid "Please report to the data.table issues tracker." msgstr "" -#: forder.c:123 +#: forder.c:119 #, c-format msgid "Failed to realloc thread private group size buffer to %d*4bytes" msgstr "" -#: forder.c:139 +#: forder.c:135 #, c-format msgid "Failed to realloc group size result to %d*4bytes" msgstr "" -#: forder.c:273 +#: forder.c:270 #, c-format msgid "" "Logical error. counts[0]=%d in cradix but should have been decremented to 0. " "radix=%d" msgstr "" -#: forder.c:291 +#: forder.c:290 msgid "Failed to alloc cradix_counts and/or cradix_tmp" msgstr "" -#: forder.c:324 +#: forder.c:322 #, c-format msgid "Unable to realloc %d * %d bytes in range_str" msgstr "" -#: forder.c:351 -msgid "Failed to alloc ustr3 when converting strings to UTF8" -msgstr "" - -#: forder.c:371 -msgid "Failed to alloc tl when converting strings to UTF8" -msgstr "" - -#: forder.c:401 +#: forder.c:404 msgid "Must an integer or numeric vector length 1" msgstr "" -#: forder.c:402 +#: forder.c:405 msgid "Must be 2, 1 or 0" msgstr "" -#: forder.c:437 +#: forder.c:440 msgid "Unknown non-finite value; not NA, NaN, -Inf or +Inf" msgstr "" -#: forder.c:476 +#: forder.c:479 msgid "" "Input is an atomic vector (not a list of columns) but order= is not a length " "1 integer" msgstr "" -#: forder.c:478 +#: forder.c:481 #, c-format msgid "forder.c received a vector type '%s' length %d\n" msgstr "" -#: forder.c:486 +#: forder.c:489 #, c-format msgid "forder.c received %d rows and %d columns\n" msgstr "" -#: forder.c:496 +#: forder.c:499 #, c-format msgid "'order' length (%d) is different to by='s length (%d)" msgstr "" -#: forder.c:509 +#: forder.c:512 #, c-format msgid "" "Column %d is length %d which differs from length of column 1 (%d), are you " "attempting to order by a list column?\n" msgstr "" -#: forder.c:513 forder.c:1683 +#: forder.c:516 forder.c:1688 msgid "retGrp must be TRUE or FALSE" msgstr "" -#: forder.c:516 forder.c:1686 +#: forder.c:519 forder.c:1691 msgid "retStats must be TRUE or FALSE" msgstr "" -#: forder.c:519 forder.c:1689 +#: forder.c:522 forder.c:1694 msgid "retStats must be TRUE whenever retGrp is TRUE" msgstr "" -#: forder.c:521 forder.c:1691 +#: forder.c:524 forder.c:1696 msgid "sort must be TRUE or FALSE" msgstr "" -#: forder.c:524 +#: forder.c:527 msgid "At least one of retGrp= or sort= must be TRUE" msgstr "" -#: forder.c:526 forder.c:1694 +#: forder.c:529 forder.c:1699 msgid "na.last must be logical TRUE, FALSE or NA of length 1" msgstr "" -#: forder.c:560 forder.c:675 +#: forder.c:562 forder.c:680 #, c-format msgid "Unable to allocate % bytes of working memory" msgstr "" -#: forder.c:578 +#: forder.c:580 #, c-format msgid "Item %d of order (ascending/descending) is %d. Must be +1 or -1." msgstr "" -#: forder.c:608 +#: forder.c:611 #, c-format msgid "" "\n" @@ -1375,146 +1336,146 @@ msgid "" "to save space and time.\n" msgstr "" -#: forder.c:620 +#: forder.c:625 #, c-format msgid "Column %d passed to [f]order is type '%s', not yet supported." msgstr "" -#: forder.c:799 +#: forder.c:804 #, c-format msgid "" "Failed to allocate TMP or UGRP or they weren't cache line aligned: nth=%d" msgstr "" -#: forder.c:808 +#: forder.c:813 msgid "Could not allocate (very tiny) group size thread buffers" msgstr "" -#: forder.c:876 +#: forder.c:881 #, c-format msgid "Timing block %2d%s = %8.3f %8d\n" msgstr "" -#: forder.c:927 forder.c:997 forder.c:1019 forder.c:1126 forder.c:1262 forder.c:1318 +#: forder.c:932 forder.c:1002 forder.c:1024 forder.c:1131 forder.c:1267 forder.c:1323 #, c-format msgid "Failed to allocate %d bytes for '%s'." msgstr "" -#: forder.c:1162 +#: forder.c:1167 #, c-format msgid "Failed to allocate parallel counts. my_n=%d, nBatch=%d" msgstr "" -#: forder.c:1174 +#: forder.c:1179 #, c-format msgid "Failed to allocate 'my_otmp' and/or 'my_ktmp' arrays (%d bytes)." msgstr "" -#: forder.c:1279 +#: forder.c:1284 #, c-format msgid "Unable to allocate TMP for my_n=%d items in parallel batch counting" msgstr "" -#: forder.c:1405 forder.c:1456 +#: forder.c:1410 forder.c:1461 #, c-format msgid "issorted 'by' [%d] out of range [1,%d]" msgstr "" -#: forder.c:1410 +#: forder.c:1415 msgid "is.sorted does not work on list columns" msgstr "" -#: forder.c:1443 forder.c:1473 forder.c:1507 +#: forder.c:1448 forder.c:1478 forder.c:1512 #, c-format msgid "type '%s' is not yet supported" msgstr "" -#: forder.c:1520 +#: forder.c:1525 msgid "x must be either NULL or an integer vector" msgstr "" -#: forder.c:1522 +#: forder.c:1527 msgid "nrow must be integer vector length 1" msgstr "" -#: forder.c:1524 +#: forder.c:1529 #, c-format msgid "nrow==%d but must be >=0" msgstr "" -#: forder.c:1541 +#: forder.c:1546 msgid "x must be type 'double'" msgstr "" -#: forder.c:1651 +#: forder.c:1656 msgid "'datatable.use.index' option must be TRUE or FALSE" msgstr "" -#: forder.c:1664 +#: forder.c:1669 msgid "'datatable.forder.auto.index' option must be TRUE or FALSE" msgstr "" -#: forder.c:1681 +#: forder.c:1686 msgid "DT is NULL" msgstr "" -#: forder.c:1697 +#: forder.c:1702 msgid "order must be integer" msgstr "" -#: forder.c:1699 +#: forder.c:1704 msgid "reuseSorting must be logical TRUE, FALSE or NA of length 1" msgstr "" -#: forder.c:1711 +#: forder.c:1716 #, c-format msgid "" "forderReuseSorting: opt not possible: is.data.table(DT)=%d, sortGroups=%d, " "all1(ascArg)=%d\n" msgstr "" -#: forder.c:1730 +#: forder.c:1735 #, c-format msgid "forderReuseSorting: using key: %s\n" msgstr "" -#: forder.c:1765 +#: forder.c:1770 #, c-format msgid "forderReuseSorting: index found but not for retGrp and retStats: %s\n" msgstr "" -#: forder.c:1768 +#: forder.c:1773 #, c-format msgid "forderReuseSorting: index found but not for retGrp: %s\n" msgstr "" -#: forder.c:1771 +#: forder.c:1776 #, c-format msgid "forderReuseSorting: index found but not for retStats: %s\n" msgstr "" -#: forder.c:1778 +#: forder.c:1783 #, c-format msgid "" "forderReuseSorting: index found but na.last=TRUE and no stats available: %s\n" msgstr "" -#: forder.c:1781 +#: forder.c:1786 #, c-format msgid "forderReuseSorting: index found but na.last=TRUE and NAs present: %s\n" msgstr "" -#: forder.c:1789 +#: forder.c:1794 #, c-format msgid "forderReuseSorting: using existing index: %s\n" msgstr "" -#: forder.c:1801 +#: forder.c:1806 #, c-format msgid "forderReuseSorting: setting index (retGrp=%d, retStats=%d) on DT: %s\n" msgstr "" -#: forder.c:1805 +#: forder.c:1810 #, c-format msgid "forderReuseSorting: opt=%d, took %.3fs\n" msgstr "" @@ -1823,11 +1784,6 @@ msgstr "" msgid " Skipped to line %d in the file" msgstr "" -#: fread.c:1766 -#, c-format -msgid "skip=% but the input only has %d line" -msgstr "" - #: fread.c:1777 msgid "" "Input is either empty, fully whitespace, or skip has been set after the last " @@ -2480,7 +2436,7 @@ msgstr "" msgid "%s: window width of size 0, returning all NaN vector\n" msgstr "" -#: froll.c:236 froll.c:424 froll.c:636 froll.c:840 froll.c:1072 froll.c:1766 +#: froll.c:236 froll.c:424 froll.c:636 froll.c:840 froll.c:1072 froll.c:1767 #, c-format msgid "" "%s: running in parallel for input length %, window %d, hasnf %d, " @@ -2545,7 +2501,7 @@ msgstr "" msgid "%s: calling sqrt(frollvarExact(...))\n" msgstr "" -#: froll.c:1508 froll.c:1769 +#: froll.c:1508 froll.c:1770 #, c-format msgid "%s: window width of size 0, returning all NA vector\n" msgstr "" @@ -2569,10 +2525,19 @@ msgstr "" #: froll.c:1628 #, c-format -msgid "%s: finding order and initializing links for %d blocks %stook %.3fs\n" +msgid "" +"%s: finding order and initializing links for %d blocks in parallel took %." +"3fs\n" msgstr "" -#: froll.c:1638 +#: froll.c:1629 +#, c-format +msgid "" +"%s: finding order and initializing links for %d blocks sequentially took %." +"3fs\n" +msgstr "" + +#: froll.c:1639 #, c-format msgid "" "%s: running implementation as described in the paper by Jukka Suomela, for " @@ -2580,17 +2545,17 @@ msgid "" "input data\n" msgstr "" -#: froll.c:1688 +#: froll.c:1689 #, c-format msgid "%s: skip rolling for %d padded elements\n" msgstr "" -#: froll.c:1721 +#: froll.c:1722 #, c-format msgid "%s: rolling took %.3f\n" msgstr "" -#: froll.c:1818 frolladaptive.c:992 +#: froll.c:1819 frolladaptive.c:992 #, c-format msgid "%s: no NAs detected, redirecting to itself using has.nf=FALSE\n" msgstr "" @@ -2894,47 +2859,30 @@ msgstr "" msgid "No data rows present (nrow==0)\n" msgstr "" -#: fwrite.c:1100 -#, c-format -msgid "" -"Written %.1f%% of % rows in %d secs using %d thread. maxBuffUsed=%d" -"%%. ETA %d secs. " -msgstr "" - -#: fwrite.c:1131 +#: fwrite.c:1132 msgid "Failed to write gzip trailer" msgstr "" -#: fwrite.c:1150 +#: fwrite.c:1151 #, c-format msgid "" "zlib: uncompressed length=%zu (%zu MiB), compressed length=%zu (%zu MiB), " "ratio=%.1f%%, crc=%x\n" msgstr "" -#: fwrite.c:1154 fwrite.c:1154 -#, c-format -msgid "Wrote % row in %.3f secs using %d thread. MaxBuffUsed=%d%%\n" -msgstr "" - -#: fwrite.c:1156 -#, c-format -msgid "Wrote % row in %.3f secs using %d threads. MaxBuffUsed=%d%%\n" -msgstr "" - -#: fwrite.c:1171 +#: fwrite.c:1172 #, c-format msgid "" "zlib %s (zlib.h %s) deflate() returned error %d Z_FINISH=%d Z_BLOCK=%d. %s" msgstr "" -#: fwrite.c:1173 +#: fwrite.c:1174 msgid "" "Please include the full output above and below this message in your data." "table bug report." msgstr "" -#: fwrite.c:1174 +#: fwrite.c:1175 msgid "" "Please retry fwrite() with verbose=TRUE and include the full output with " "your data.table bug report." @@ -3196,117 +3144,117 @@ msgstr "" msgid "Final step, fetching indices in overlaps ... done in %8.3f seconds\n" msgstr "" -#: init.c:182 +#: init.c:183 msgid "" "Pointers are %zu bytes, greater than 8. We have not tested on any " "architecture greater than 64bit yet." msgstr "" -#: init.c:196 +#: init.c:197 msgid "... failed. Please forward this message to maintainer('data.table')." msgstr "" -#: init.c:197 +#: init.c:198 #, c-format msgid "Checking NA_INTEGER [%d] == INT_MIN [%d] %s" msgstr "" -#: init.c:198 +#: init.c:199 #, c-format msgid "Checking NA_INTEGER [%d] == NA_LOGICAL [%d] %s" msgstr "" -#: init.c:199 init.c:200 init.c:202 init.c:205 init.c:206 init.c:207 init.c:208 init.c:209 init.c:210 init.c:211 +#: init.c:200 init.c:201 init.c:203 init.c:206 init.c:207 init.c:208 init.c:209 init.c:210 init.c:211 init.c:212 #, c-format msgid "Checking sizeof(%s) [%zu] is %d %s" msgstr "" -#: init.c:203 +#: init.c:204 #, c-format msgid "Checking sizeof(pointer) [%zu] is 4 or 8 %s" msgstr "" -#: init.c:204 +#: init.c:205 #, c-format msgid "Checking sizeof(SEXP) [%zu] == sizeof(pointer) [%zu] %s" msgstr "" -#: init.c:214 +#: init.c:215 #, c-format msgid "Checking LENGTH(allocVector(INTSXP,2)) [%d] is 2 %s" msgstr "" -#: init.c:221 +#: init.c:222 #, c-format msgid "Checking memset(&i,0,sizeof(int)); i == (int)0 %s" msgstr "" -#: init.c:224 +#: init.c:225 #, c-format msgid "Checking memset(&ui, 0, sizeof(unsigned int)); ui == (unsigned int)0 %s" msgstr "" -#: init.c:227 +#: init.c:228 #, c-format msgid "Checking memset(&d, 0, sizeof(double)); d == (double)0.0 %s" msgstr "" -#: init.c:230 +#: init.c:231 #, c-format msgid "Checking memset(&ld, 0, sizeof(long double)); ld == (long double)0.0 %s" msgstr "" -#: init.c:233 +#: init.c:234 msgid "" "Unlike the very common case, e.g. ASCII, the character '/' is not just " "before '0'." msgstr "" -#: init.c:234 +#: init.c:235 msgid "The C expression (uint_fast8_t)('/'-'0')<10 is true. Should be false." msgstr "" -#: init.c:235 +#: init.c:236 msgid "" "Unlike the very common case, e.g. ASCII, the character ':' is not just after " "'9'." msgstr "" -#: init.c:236 +#: init.c:237 msgid "The C expression (uint_fast8_t)('9'-':')<10 is true. Should be false." msgstr "" -#: init.c:241 +#: init.c:242 #, c-format msgid "Conversion of NA_INT64 via double failed %!=%" msgstr "" -#: init.c:245 +#: init.c:246 msgid "NA_INT64_D (negative -0.0) is not == 0.0." msgstr "" -#: init.c:246 +#: init.c:247 msgid "NA_INT64_D (negative -0.0) is not ==-0.0." msgstr "" -#: init.c:247 +#: init.c:248 msgid "ISNAN(NA_INT64_D) is TRUE but should not be" msgstr "" -#: init.c:248 +#: init.c:249 msgid "isnan(NA_INT64_D) is TRUE but should not be" msgstr "" -#: init.c:282 +#: init.c:283 #, c-format msgid "PRINTNAME(install(\"integer64\")) has returned %s not %s" msgstr "" -#: init.c:341 +#: init.c:342 msgid "verbose option must be length 1 non-NA logical or integer" msgstr "" -#: init.c:366 +#: init.c:367 msgid ".Last.updated in namespace is not a length 1 integer" msgstr "" @@ -3362,11 +3310,6 @@ msgstr "" msgid "fill must be a vector of length 1 or a list of length of x." msgstr "" -#: nafill.c:237 -#, c-format -msgid "%s: parallel processing of %d column took %.3fs\n" -msgstr "" - #: negate.c:6 msgid "not logical or integer vector" msgstr "" @@ -3459,13 +3402,6 @@ msgid "" "length %d. Only length-1 columns are recycled." msgstr "" -#: rbindlist.c:61 -#, c-format -msgid "" -"Column %d ['%s'] of item %d is length 0. This (and %d other like it) has " -"been filled with NA (NULL for list columns) to make each item uniform." -msgstr "" - #: rbindlist.c:66 #, c-format msgid "" @@ -3477,38 +3413,31 @@ msgstr "" msgid "use.names=TRUE but no item of input list has any names" msgstr "" -#: rbindlist.c:76 -#, c-format -msgid "" -"Failed to allocate upper bound of % unique column names " -"[sum(lapply(l,ncol))]" -msgstr "" - -#: rbindlist.c:105 +#: rbindlist.c:106 #, c-format msgid "Failed to allocate nuniq=%d items working memory in rbindlist.c" msgstr "" -#: rbindlist.c:140 +#: rbindlist.c:139 #, c-format msgid "Failed to allocate ncol=%d items working memory in rbindlist.c" msgstr "" -#: rbindlist.c:201 +#: rbindlist.c:199 msgid "" " use.names='check' (default from v1.12.2) emits this message and proceeds as " "if use.names=FALSE for backwards compatibility. See news item 5 in v1.12.2 " "for options to control this message." msgstr "" -#: rbindlist.c:215 +#: rbindlist.c:213 #, c-format msgid "" "Column %d ['%s'] of item %d is missing in item %d. Use fill=TRUE to fill " "with NA (NULL for list columns), or use.names=FALSE to ignore column names.%s" msgstr "" -#: rbindlist.c:224 +#: rbindlist.c:222 #, c-format msgid "" "Column %d ['%s'] of item %d appears in position %d in item %d. Set use." @@ -3516,40 +3445,40 @@ msgid "" "names.%s" msgstr "" -#: rbindlist.c:233 +#: rbindlist.c:231 msgid "" "options()$datatable.rbindlist.check is set but is not a single string. See " "news item 5 in v1.12.2." msgstr "" -#: rbindlist.c:240 +#: rbindlist.c:238 #, c-format msgid "" "options()$datatable.rbindlist.check=='%s' which is not 'message'|'warning'|" "'error'|'none'. See news item 5 in v1.12.2." msgstr "" -#: rbindlist.c:303 +#: rbindlist.c:301 #, c-format msgid "" "Column %d of item %d has type 'factor' but has no levels; i.e. malformed." msgstr "" -#: rbindlist.c:332 +#: rbindlist.c:330 #, c-format msgid "" "Class attribute on column %d of item %d does not match with column %d of " "item %d. You can deactivate this safety-check by using ignore.attr=TRUE" msgstr "" -#: rbindlist.c:383 +#: rbindlist.c:380 rbindlist.c:389 #, c-format msgid "" "Failed to allocate working memory for %d ordered factor levels of result " "column %d" msgstr "" -#: rbindlist.c:406 +#: rbindlist.c:408 #, c-format msgid "" "Column %d of item %d is an ordered factor but level %d ['%s'] is missing " @@ -3558,7 +3487,7 @@ msgid "" "factor will be created for this column." msgstr "" -#: rbindlist.c:411 +#: rbindlist.c:413 #, c-format msgid "" "Column %d of item %d is an ordered factor with '%s'<'%s' in its levels. But " @@ -3566,14 +3495,14 @@ msgid "" "will be created for this column due to this ambiguity." msgstr "" -#: rbindlist.c:456 +#: rbindlist.c:456 rbindlist.c:465 #, c-format msgid "" "Failed to allocate working memory for %d factor levels of result column %d " "when reading item %d of item %d" msgstr "" -#: rbindlist.c:548 rbindlist.c:551 +#: rbindlist.c:553 rbindlist.c:556 #, c-format msgid "Column %d of item %d: %s" msgstr "" @@ -3745,87 +3674,82 @@ msgstr "" msgid "x is not a logical vector" msgstr "" -#: utils.c:96 +#: utils.c:100 #, c-format msgid "Unsupported type '%s' passed to allNA()" msgstr "" -#: utils.c:116 +#: utils.c:120 msgid "'x' argument must be data.table compatible" msgstr "" -#: utils.c:140 +#: utils.c:144 msgid "" "argument specifying columns is type 'double' and one or more items in it are " "not whole integers" msgstr "" -#: utils.c:146 +#: utils.c:150 #, c-format msgid "" "argument specifying columns received non-existing column(s): cols[%d]=%d" msgstr "" -#: utils.c:153 +#: utils.c:157 msgid "'x' argument data.table has no names" msgstr "" -#: utils.c:159 +#: utils.c:163 #, c-format msgid "" "argument specifying columns received non-existing column(s): cols[%d]='%s'" msgstr "" -#: utils.c:163 +#: utils.c:167 msgid "argument specifying columns must be character or numeric" msgstr "" -#: utils.c:166 +#: utils.c:170 msgid "argument specifying columns received duplicate column(s)" msgstr "" -#: utils.c:307 -#, c-format -msgid "Found and copied %d column with a shared memory address\n" -msgstr "" - -#: utils.c:389 +#: utils.c:381 msgid "'x' is not atomic" msgstr "" -#: utils.c:391 +#: utils.c:383 msgid "'x' must not be matrix or array" msgstr "" -#: utils.c:393 +#: utils.c:385 msgid "input must not be matrix or array" msgstr "" -#: utils.c:397 +#: utils.c:389 #, c-format msgid "copy=false and input already of expected type and class %s[%s]\n" msgstr "" -#: utils.c:404 +#: utils.c:396 #, c-format msgid "Coercing %s[%s] into %s[%s]\n" msgstr "" -#: utils.c:420 +#: utils.c:412 #, c-format msgid "zlib header files were not found when data.table was compiled" msgstr "" -#: utils.c:546 +#: utils.c:538 msgid "'x' should not be data.frame or data.table." msgstr "" -#: utils.c:548 +#: utils.c:540 #, c-format msgid "%s must be TRUE or FALSE." msgstr "" -#: utils.c:629 +#: utils.c:621 #, c-format msgid "Type '%s' is not supported by frev" msgstr "" diff --git a/src/init.c b/src/init.c index e4e77e96c..8a305192c 100644 --- a/src/init.c +++ b/src/init.c @@ -371,5 +371,5 @@ SEXP initLastUpdated(SEXP var) { SEXP dllVersion(void) { // .onLoad calls this and checks the same as packageVersion() to ensure no R/C version mismatch, #3056 - return(ScalarString(mkChar("1.17.99"))); + return(ScalarString(mkChar("1.18.0"))); } From 8073130e4a7f8f545e16130d5deae3d825c30c4c Mon Sep 17 00:00:00 2001 From: Tyson Barrett Date: Wed, 24 Dec 2025 16:19:58 -0700 Subject: [PATCH 2/2] bump version to dev --- .dev/CRAN_Release.cmd | 36 ++-- DESCRIPTION | 2 +- Makefile | 6 +- NEWS.md | 3 + src/init.c | 444 +++++++++++++++++++++++------------------- 5 files changed, 273 insertions(+), 218 deletions(-) diff --git a/.dev/CRAN_Release.cmd b/.dev/CRAN_Release.cmd index e7790ece8..e2b930b0c 100644 --- a/.dev/CRAN_Release.cmd +++ b/.dev/CRAN_Release.cmd @@ -47,12 +47,12 @@ rm -rf ./data.table.Rcheck checkbashisms ./configure # for portability; e.g. Solaris 10 running Bourne shell; #3964 -# Ensure no non-ASCII, other than in README.md is ok +# Ensure no non-ASCII, other than in README.md DESCRIPTION vignettes *.yml and *.po are ok # tests.Rraw in particular have failed CRAN Solaris (only) due to this. -grep -RI --exclude-dir=".git" --exclude="*.md" --exclude="*~" --color='auto' -P -n "[\x80-\xFF]" ./ +grep -RI --exclude-dir=".git" --exclude-dir="vignettes" --exclude="*.yml" --exclude="*.md" --exclude="*.po" --exclude="*~" --exclude="DESCRIPTION" --color='auto' -P -n "[\x80-\xFF]" ./ # Unicode is now ok. This unicode in tests.Rraw is passing on CRAN. -grep -RI --exclude-dir=".git" --exclude="*.md" --exclude="*~" --color='auto' -n "[\]u[0-9]" ./ +# grep -RI --exclude-dir=".git" --exclude="*.md" --exclude="*~" --color='auto' -n "[\]u[0-9]" ./ # Ensure no calls to omp_get_max_threads() also since access should be via getDTthreads() grep --exclude="./src/openmp-utils.c" omp_get_max_threads ./src/* @@ -80,14 +80,14 @@ grep "Rprintf" ./src/init.c # workaround for IBM AIX - ensure no globals named 'nearest' or 'class'. # See https://github.com/Rdatatable/data.table/issues/1351 grep "nearest *=" ./src/*.c # none -grep "class *=" ./src/*.c # quite a few but none global +grep "class *=" ./src/*.c # only one # ensure no use of z_const from zconf.h; #3939 grep "z_const" ./src/*.[hc] # none other than the comment # No undefined type punning of the form: *(long long *)&REAL(column)[i] # Failed clang 3.9.1 -O3 due to this, I think. -grep "&REAL" ./src/*.c +grep "&REAL" ./src/*.c # one instance in init.c # No [UN]PROTECT_PTR, #3232 grep "PROTECT_PTR" ./src/*.c @@ -107,13 +107,13 @@ grep -n "[^A-Za-z0-9]F[^A-Za-z0-9]" ./inst/tests/tests.Rraw grep -Enr "\bifelse" R # use substr() instead of substring(), #4447 -grep -Fnr "substring" R +grep -Fnr "substring" R # one instance in test.data.table.R # No system.time in main tests.Rraw. Timings should be in benchmark.Rraw -grep -Fn "system.time" ./inst/tests/*.Rraw | grep -Fv "benchmark.Rraw" | grep -Fv "this system.time usage ok" +grep -Fn "system.time" ./inst/tests/*.Rraw | grep -Fv "benchmark.Rraw" | grep -Fv "this system.time usage ok" # only in froll.Rraw # No tryCatch in *.Rraw -- tryCatch should be handled only in test() itself to avoid silently missed warnings/errors/output -grep -Fn "tryCatch" ./inst/tests/*.Rraw +grep -Fn "tryCatch" ./inst/tests/*.Rraw # only one outside of test() ./inst/tests/tests.Rraw:21594 # All % in *.Rd should be escaped otherwise text gets silently chopped grep -n "[^\]%" ./man/*.Rd @@ -168,8 +168,8 @@ R CMD build . export GITHUB_PAT="f1c.. github personal access token ..7ad" # avoids many too-many-requests in --as-cran's ping-all-URLs step (20 mins) inside the `checking CRAN incoming feasibility...` step. # Many thanks to Dirk for the tipoff that setting this env variable solves the problem, #4832. -R CMD check data.table_1.16.99.tar.gz --as-cran -R CMD INSTALL data.table_1.16.99.tar.gz --html +R CMD check data.table_1.18.99.tar.gz --as-cran +R CMD INSTALL data.table_1.18.99.tar.gz --html # Test C locale doesn't break test suite (#2771) echo LC_ALL=C > ~/.Renviron @@ -193,9 +193,9 @@ q("no") # User supplied PKG_CFLAGS and PKG_LIBS passed through, #4664 # Next line from https://mac.r-project.org/openmp/. Should see the arguments passed through and then fail with gcc on linux. -PKG_CFLAGS='-Xclang -fopenmp' PKG_LIBS=-lomp R CMD INSTALL data.table_1.16.99.tar.gz +PKG_CFLAGS='-Xclang -fopenmp' PKG_LIBS=-lomp R CMD INSTALL data.table_1.18.99.tar.gz # Next line should work on Linux, just using superfluous and duplicate but valid parameters here to see them retained and work -PKG_CFLAGS='-fopenmp' PKG_LIBS=-lz R CMD INSTALL data.table_1.16.99.tar.gz +PKG_CFLAGS='-fopenmp' PKG_LIBS=-lz R CMD INSTALL data.table_1.18.99.tar.gz R remove.packages("xml2") # we checked the URLs; don't need to do it again (many minutes) @@ -239,7 +239,7 @@ alias R340=~/build/R-3.4.0/bin/R ### END ONE TIME BUILD cd ~/GitHub/data.table -R340 CMD INSTALL ./data.table_1.16.99.tar.gz +R340 CMD INSTALL ./data.table_1.18.99.tar.gz R340 require(data.table) test.data.table(script="*.Rraw") @@ -251,7 +251,7 @@ test.data.table(script="*.Rraw") vi ~/.R/Makevars # Make line SHLIB_OPENMP_CFLAGS= active to remove -fopenmp R CMD build . -R CMD INSTALL data.table_1.16.99.tar.gz # ensure that -fopenmp is missing and there are no warnings +R CMD INSTALL data.table_1.18.99.tar.gz # ensure that -fopenmp is missing and there are no warnings R require(data.table) # observe startup message about no OpenMP detected test.data.table() @@ -259,7 +259,7 @@ q("no") vi ~/.R/Makevars # revert change above R CMD build . -R CMD check data.table_1.16.99.tar.gz +R CMD check data.table_1.18.99.tar.gz ##################################################### @@ -568,7 +568,7 @@ du -k inst/tests # 0.75MiB after R CMD build . export GITHUB_PAT="f1c.. github personal access token ..7ad" Rdevel -q -e "packageVersion('xml2')" # ensure installed -Rdevel CMD check data.table_1.17.0.tar.gz --as-cran # use latest Rdevel as it may have extra checks +Rdevel CMD check data.table_1.18.0.tar.gz --as-cran # use latest Rdevel as it may have extra checks bunzip2 inst/tests/*.Rraw.bz2 # decompress *.Rraw again so as not to commit compressed *.Rraw to git # @@ -596,12 +596,12 @@ bunzip2 inst/tests/*.Rraw.bz2 # decompress *.Rraw again so as not to commit com # 0. Start a new branch `cran-x.y.0` with the code as submitted to CRAN # - Check that 'git status' shows 4 files in modified and uncommitted state: DESCRIPTION, NEWS.md, init.c and this .dev/CRAN_Release.cmd # - The branch should have one commit with precisely these 4 files being edited -# 1. Follow up with a commit with this consistent commit message like: "1.17.0 on CRAN. Bump to 1.17.99" to this branch bumping to the next dev version +# 1. Follow up with a commit with this consistent commit message like: "1.18.0 on CRAN. Bump to 1.18.99" to this branch bumping to the next dev version # - Bump minor version in DESCRIPTION to next odd number. Note that DESCRIPTION was in edited and uncommitted state so even number never appears in git. # - Add new heading in NEWS for the next dev version. Add "(submitted to CRAN on )" on the released heading. # - Bump minor version in dllVersion() in init.c # - Bump 3 minor version numbers in Makefile -# - Search and replace this .dev/CRAN_Release.cmd to update 1.16.99 to 1.16.99 inc below, 1.16.0 to 1.17.0 above, 1.15.0 to 1.16.0 below +# - Search and replace this .dev/CRAN_Release.cmd to update 1.17.99 to 1.18.99 inc below, 1.17.0 to 1.18.0 # - Another final gd to view all diffs using meld. (I have `alias gd='git difftool &> /dev/null'` and difftool meld: http://meldmerge.org/) # 2. Ideally, no PRs are reviewed while a CRAN submission is pending. Any reviews that do happen MUST target this branch, NOT master! # 3. Once the submission lands on CRAN, merge this branch WITHOUT SQUASHING! diff --git a/DESCRIPTION b/DESCRIPTION index ab359df08..f8a1f6d8f 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,5 +1,5 @@ Package: data.table -Version: 1.18.0 +Version: 1.18.99 Title: Extension of `data.frame` Depends: R (>= 3.4.0) Imports: methods diff --git a/Makefile b/Makefile index 25ed4fd81..d34e1427a 100644 --- a/Makefile +++ b/Makefile @@ -18,7 +18,7 @@ some: .PHONY: clean clean: - $(RM) data.table_1.17.99.tar.gz + $(RM) data.table_1.18.99.tar.gz $(RM) src/*.o $(RM) src/*.so @@ -28,7 +28,7 @@ build: .PHONY: install install: - $(R) CMD INSTALL data.table_1.17.99.tar.gz + $(R) CMD INSTALL data.table_1.18.99.tar.gz .PHONY: uninstall uninstall: @@ -40,7 +40,7 @@ test: .PHONY: check check: - _R_CHECK_CRAN_INCOMING_REMOTE_=false $(R) CMD check data.table_1.17.99.tar.gz --as-cran --ignore-vignettes --no-stop-on-test-error + _R_CHECK_CRAN_INCOMING_REMOTE_=false $(R) CMD check data.table_1.18.99.tar.gz --as-cran --ignore-vignettes --no-stop-on-test-error .PHONY: revision revision: diff --git a/NEWS.md b/NEWS.md index aed1752d8..5c97d3b69 100644 --- a/NEWS.md +++ b/NEWS.md @@ -2,6 +2,9 @@ **If you are viewing this file on CRAN, please check [latest news on GitHub](https://github.com/Rdatatable/data.table/blob/master/NEWS.md) where the formatting is also better.** +## data.table [v1.18.99](https://github.com/Rdatatable/data.table/milestone/37?closed=1) (in development) + + ## data.table [v1.18.0](https://github.com/Rdatatable/data.table/milestone/37?closed=1) 23 December 2025 ### BREAKING CHANGE diff --git a/src/init.c b/src/init.c index 8a305192c..13421998b 100644 --- a/src/init.c +++ b/src/init.c @@ -49,138 +49,147 @@ Rcomplex NA_CPLX; size_t r_type_sizes[100]; size_t r_type_order[100]; -static const -R_CallMethodDef callMethods[] = { -{"Csetattrib", (DL_FUNC) &setattrib, -1}, -{"Cbmerge", (DL_FUNC) &bmerge, -1}, -{"Cassign", (DL_FUNC) &assign, -1}, -{"Cdogroups", (DL_FUNC) &dogroups, -1}, -{"Ccopy", (DL_FUNC) ©, -1}, -{"Cshallowwrapper", (DL_FUNC) &shallowwrapper, -1}, -{"Csetdt_nrows", (DL_FUNC) &setdt_nrows, -1}, -{"Calloccolwrapper", (DL_FUNC) &alloccolwrapper, -1}, -{"Cselfrefokwrapper", (DL_FUNC) &selfrefokwrapper, -1}, -{"Ctruelength", (DL_FUNC) &truelength, -1}, -{"Csetcharvec", (DL_FUNC) &setcharvec, -1}, -{"Csetcolorder", (DL_FUNC) &setcolorder, -1}, -{"Cchmatch", (DL_FUNC) &chmatch_R, -1}, -{"Cchmatchdup", (DL_FUNC) &chmatchdup_R, -1}, -{"Cchin", (DL_FUNC) &chin_R, -1}, -{"CfreadR", (DL_FUNC) &freadR, -1}, -{"CfwriteR", (DL_FUNC) &fwriteR, -1}, -{"Creorder", (DL_FUNC) &reorder, -1}, -{"Crbindlist", (DL_FUNC) &rbindlist, -1}, -{"Cvecseq", (DL_FUNC) &vecseq, -1}, -{"Csetlistelt", (DL_FUNC) &setlistelt, -1}, -{"CsetS4elt", (DL_FUNC) &setS4elt, -1}, -{"Caddress", (DL_FUNC) &address, -1}, -{"CexpandAltRep", (DL_FUNC) &expandAltRep, -1}, -{"Cfmelt", (DL_FUNC) &fmelt, -1}, -{"Cfcast", (DL_FUNC) &fcast, -1}, -{"Cuniqlist", (DL_FUNC) &uniqlist, -1}, -{"Cuniqlengths", (DL_FUNC) &uniqlengths, -1}, -{"CforderReuseSorting", (DL_FUNC) &forderReuseSorting, -1}, -{"Cforder", (DL_FUNC) &forder, -1}, -{"Cissorted", (DL_FUNC) &issorted, -1}, -{"Cgforce", (DL_FUNC) &gforce, -1}, -{"Cgsum", (DL_FUNC) &gsum, -1}, -{"Cgmean", (DL_FUNC) &gmean, -1}, -{"Cgmin", (DL_FUNC) &gmin, -1}, -{"Cgmax", (DL_FUNC) &gmax, -1}, -{"CisOrderedSubset", (DL_FUNC) &isOrderedSubset, -1}, -{"CsetNumericRounding", (DL_FUNC) &setNumericRounding, -1}, -{"CgetNumericRounding", (DL_FUNC) &getNumericRounding, -1}, -{"Cbinary", (DL_FUNC) &binary, -1}, -{"CsubsetDT", (DL_FUNC) &subsetDT, -1}, -{"CsubsetVector", (DL_FUNC) &subsetVector, -1}, -{"CconvertNegAndZeroIdx", (DL_FUNC) &convertNegAndZeroIdx, -1}, -{"Cfrank", (DL_FUNC) &frank, -1}, -{"Cdt_na", (DL_FUNC) &dt_na, -1}, -{"Clookup", (DL_FUNC) &lookup, -1}, -{"Coverlaps", (DL_FUNC) &overlaps, -1}, -{"Cwhichwrapper", (DL_FUNC) &whichwrapper, -1}, -{"Cshift", (DL_FUNC) &shift, -1}, -{"Ctranspose", (DL_FUNC) &transpose, -1}, -{"CanyNA", (DL_FUNC) &anyNA, -1}, -{"CfitsInInt32R", (DL_FUNC) &fitsInInt32R, -1}, -{"CfitsInInt64R", (DL_FUNC) &fitsInInt64R, -1}, -{"Csetlevels", (DL_FUNC) &setlevels, -1}, -{"Crleid", (DL_FUNC) &rleid, -1}, -{"Cgmedian", (DL_FUNC) &gmedian, -1}, -{"Cgtail", (DL_FUNC) >ail, -1}, -{"Cghead", (DL_FUNC) &ghead, -1}, -{"Cglast", (DL_FUNC) &glast, -1}, -{"Cgfirst", (DL_FUNC) &gfirst, -1}, -{"Cgnthvalue", (DL_FUNC) &gnthvalue, -1}, -{"Cdim", (DL_FUNC) &dim, -1}, -{"Cgvar", (DL_FUNC) &gvar, -1}, -{"Cgsd", (DL_FUNC) &gsd, -1}, -{"Cgprod", (DL_FUNC) &gprod, -1}, -{"Cgshift", (DL_FUNC) &gshift, -1}, -{"Cnestedid", (DL_FUNC) &nestedid, -1}, -{"CsetDTthreads", (DL_FUNC) &setDTthreads, -1}, -{"CgetDTthreads", (DL_FUNC) &getDTthreads_R, -1}, -{"CgetDTthreadsC", (DL_FUNC) &getDTthreads_C, -1}, -{"CnqRecreateIndices", (DL_FUNC) &nqRecreateIndices, -1}, -{"Cfsort", (DL_FUNC) &fsort, -1}, -{"Cinrange", (DL_FUNC) &inrange, -1}, -{"Cbetween", (DL_FUNC) &between, -1}, -{"ChasOpenMP", (DL_FUNC) &hasOpenMP, -1}, -{"CuniqueNlogical", (DL_FUNC) &uniqueNlogical, -1}, -{"CfrollfunR", (DL_FUNC) &frollfunR, -1}, -{"CdllVersion", (DL_FUNC) &dllVersion, -1}, -{"CnafillR", (DL_FUNC) &nafillR, -1}, -{"CcolnamesInt", (DL_FUNC) &colnamesInt, -1}, -{"CinitLastUpdated", (DL_FUNC) &initLastUpdated, -1}, -{"Ccj", (DL_FUNC) &cj, -1}, -{"Ccoalesce", (DL_FUNC) &coalesce, -1}, -{"CfifelseR", (DL_FUNC) &fifelseR, -1}, -{"CfcaseR", (DL_FUNC) &fcaseR, -1}, -{"C_lock", (DL_FUNC) &lock, -1}, // _ for these 3 to avoid Clock as in time -{"C_unlock", (DL_FUNC) &unlock, -1}, -{"C_islocked", (DL_FUNC) &islockedR, -1}, -{"CtestMsgR", (DL_FUNC) &testMsgR, -1}, -{"C_allNAR", (DL_FUNC) &allNAR, -1}, -{"CcoerceAs", (DL_FUNC) &coerceAs, -1}, -{"Ctest_dt_win_snprintf", (DL_FUNC)&test_dt_win_snprintf, -1}, -{"Cdt_zlib_version", (DL_FUNC)&dt_zlib_version, -1}, -{"Cdt_has_zlib", (DL_FUNC)&dt_has_zlib, -1}, -{"Csubstitute_call_arg_namesR", (DL_FUNC) &substitute_call_arg_namesR, -1}, -{"CstartsWithAny", (DL_FUNC)&startsWithAny, -1}, -{"CconvertDate", (DL_FUNC)&convertDate, -1}, -{"Cnotchin", (DL_FUNC)¬chin, -1}, -{"Ccbindlist", (DL_FUNC) &cbindlist, -1}, -{"CperhapsDataTableR", (DL_FUNC) &perhapsDataTableR, -1}, -{"CcopyCols", (DL_FUNC) ©Cols, -1}, -{"Cwarn_matrix_column_r", (DL_FUNC)&warn_matrix_column_r, -1}, -{"Cfrev", (DL_FUNC) &frev, -1}, -{"CmemcpyVector", (DL_FUNC)&memcpyVector, -1}, -{"CmemcpyDT", (DL_FUNC)&memcpyDT, -1}, -{"CmemcpyVectoradaptive", (DL_FUNC)&memcpyVectoradaptive, -1}, -{"CmemcpyDTadaptive", (DL_FUNC)&memcpyDTadaptive, -1}, -{"CcopyAsGrowable", (DL_FUNC)©AsGrowable, -1}, -{"Cfrolladapt", (DL_FUNC)&frolladapt, -1}, -{"Cis_direct_child", (DL_FUNC)&is_direct_child, -1}, -{NULL, NULL, 0} -}; +static const R_CallMethodDef callMethods[] = { + {"Csetattrib", (DL_FUNC)&setattrib, -1}, + {"Cbmerge", (DL_FUNC)&bmerge, -1}, + {"Cassign", (DL_FUNC)&assign, -1}, + {"Cdogroups", (DL_FUNC)&dogroups, -1}, + {"Ccopy", (DL_FUNC)©, -1}, + {"Cshallowwrapper", (DL_FUNC)&shallowwrapper, -1}, + {"Csetdt_nrows", (DL_FUNC)&setdt_nrows, -1}, + {"Calloccolwrapper", (DL_FUNC)&alloccolwrapper, -1}, + {"Cselfrefokwrapper", (DL_FUNC)&selfrefokwrapper, -1}, + {"Ctruelength", (DL_FUNC)&truelength, -1}, + {"Csetcharvec", (DL_FUNC)&setcharvec, -1}, + {"Csetcolorder", (DL_FUNC)&setcolorder, -1}, + {"Cchmatch", (DL_FUNC)&chmatch_R, -1}, + {"Cchmatchdup", (DL_FUNC)&chmatchdup_R, -1}, + {"Cchin", (DL_FUNC)&chin_R, -1}, + {"CfreadR", (DL_FUNC)&freadR, -1}, + {"CfwriteR", (DL_FUNC)&fwriteR, -1}, + {"Creorder", (DL_FUNC)&reorder, -1}, + {"Crbindlist", (DL_FUNC)&rbindlist, -1}, + {"Cvecseq", (DL_FUNC)&vecseq, -1}, + {"Csetlistelt", (DL_FUNC)&setlistelt, -1}, + {"CsetS4elt", (DL_FUNC)&setS4elt, -1}, + {"Caddress", (DL_FUNC)&address, -1}, + {"CexpandAltRep", (DL_FUNC)&expandAltRep, -1}, + {"Cfmelt", (DL_FUNC)&fmelt, -1}, + {"Cfcast", (DL_FUNC)&fcast, -1}, + {"Cuniqlist", (DL_FUNC)&uniqlist, -1}, + {"Cuniqlengths", (DL_FUNC)&uniqlengths, -1}, + {"CforderReuseSorting", (DL_FUNC)&forderReuseSorting, -1}, + {"Cforder", (DL_FUNC)&forder, -1}, + {"Cissorted", (DL_FUNC)&issorted, -1}, + {"Cgforce", (DL_FUNC)&gforce, -1}, + {"Cgsum", (DL_FUNC)&gsum, -1}, + {"Cgmean", (DL_FUNC)&gmean, -1}, + {"Cgmin", (DL_FUNC)&gmin, -1}, + {"Cgmax", (DL_FUNC)&gmax, -1}, + {"CisOrderedSubset", (DL_FUNC)&isOrderedSubset, -1}, + {"CsetNumericRounding", (DL_FUNC)&setNumericRounding, -1}, + {"CgetNumericRounding", (DL_FUNC)&getNumericRounding, -1}, + {"Cbinary", (DL_FUNC)&binary, -1}, + {"CsubsetDT", (DL_FUNC)&subsetDT, -1}, + {"CsubsetVector", (DL_FUNC)&subsetVector, -1}, + {"CconvertNegAndZeroIdx", (DL_FUNC)&convertNegAndZeroIdx, -1}, + {"Cfrank", (DL_FUNC)&frank, -1}, + {"Cdt_na", (DL_FUNC)&dt_na, -1}, + {"Clookup", (DL_FUNC)&lookup, -1}, + {"Coverlaps", (DL_FUNC)&overlaps, -1}, + {"Cwhichwrapper", (DL_FUNC)&whichwrapper, -1}, + {"Cshift", (DL_FUNC)&shift, -1}, + {"Ctranspose", (DL_FUNC)&transpose, -1}, + {"CanyNA", (DL_FUNC)&anyNA, -1}, + {"CfitsInInt32R", (DL_FUNC)&fitsInInt32R, -1}, + {"CfitsInInt64R", (DL_FUNC)&fitsInInt64R, -1}, + {"Csetlevels", (DL_FUNC)&setlevels, -1}, + {"Crleid", (DL_FUNC)&rleid, -1}, + {"Cgmedian", (DL_FUNC)&gmedian, -1}, + {"Cgtail", (DL_FUNC)>ail, -1}, + {"Cghead", (DL_FUNC)&ghead, -1}, + {"Cglast", (DL_FUNC)&glast, -1}, + {"Cgfirst", (DL_FUNC)&gfirst, -1}, + {"Cgnthvalue", (DL_FUNC)&gnthvalue, -1}, + {"Cdim", (DL_FUNC)&dim, -1}, + {"Cgvar", (DL_FUNC)&gvar, -1}, + {"Cgsd", (DL_FUNC)&gsd, -1}, + {"Cgprod", (DL_FUNC)&gprod, -1}, + {"Cgshift", (DL_FUNC)&gshift, -1}, + {"Cnestedid", (DL_FUNC)&nestedid, -1}, + {"CsetDTthreads", (DL_FUNC)&setDTthreads, -1}, + {"CgetDTthreads", (DL_FUNC)&getDTthreads_R, -1}, + {"CgetDTthreadsC", (DL_FUNC)&getDTthreads_C, -1}, + {"CnqRecreateIndices", (DL_FUNC)&nqRecreateIndices, -1}, + {"Cfsort", (DL_FUNC)&fsort, -1}, + {"Cinrange", (DL_FUNC)&inrange, -1}, + {"Cbetween", (DL_FUNC)&between, -1}, + {"ChasOpenMP", (DL_FUNC)&hasOpenMP, -1}, + {"CuniqueNlogical", (DL_FUNC)&uniqueNlogical, -1}, + {"CfrollfunR", (DL_FUNC)&frollfunR, -1}, + {"CdllVersion", (DL_FUNC)&dllVersion, -1}, + {"CnafillR", (DL_FUNC)&nafillR, -1}, + {"CcolnamesInt", (DL_FUNC)&colnamesInt, -1}, + {"CinitLastUpdated", (DL_FUNC)&initLastUpdated, -1}, + {"Ccj", (DL_FUNC)&cj, -1}, + {"Ccoalesce", (DL_FUNC)&coalesce, -1}, + {"CfifelseR", (DL_FUNC)&fifelseR, -1}, + {"CfcaseR", (DL_FUNC)&fcaseR, -1}, + {"C_lock", (DL_FUNC)&lock, -1}, // _ for these 3 to avoid Clock as in time + {"C_unlock", (DL_FUNC)&unlock, -1}, + {"C_islocked", (DL_FUNC)&islockedR, -1}, + {"CtestMsgR", (DL_FUNC)&testMsgR, -1}, + {"C_allNAR", (DL_FUNC)&allNAR, -1}, + {"CcoerceAs", (DL_FUNC)&coerceAs, -1}, + {"Ctest_dt_win_snprintf", (DL_FUNC)&test_dt_win_snprintf, -1}, + {"Cdt_zlib_version", (DL_FUNC)&dt_zlib_version, -1}, + {"Cdt_has_zlib", (DL_FUNC)&dt_has_zlib, -1}, + {"Csubstitute_call_arg_namesR", (DL_FUNC)&substitute_call_arg_namesR, -1}, + {"CstartsWithAny", (DL_FUNC)&startsWithAny, -1}, + {"CconvertDate", (DL_FUNC)&convertDate, -1}, + {"Cnotchin", (DL_FUNC)¬chin, -1}, + {"Ccbindlist", (DL_FUNC)&cbindlist, -1}, + {"CperhapsDataTableR", (DL_FUNC)&perhapsDataTableR, -1}, + {"CcopyCols", (DL_FUNC)©Cols, -1}, + {"Cwarn_matrix_column_r", (DL_FUNC)&warn_matrix_column_r, -1}, + {"Cfrev", (DL_FUNC)&frev, -1}, + {"CmemcpyVector", (DL_FUNC)&memcpyVector, -1}, + {"CmemcpyDT", (DL_FUNC)&memcpyDT, -1}, + {"CmemcpyVectoradaptive", (DL_FUNC)&memcpyVectoradaptive, -1}, + {"CmemcpyDTadaptive", (DL_FUNC)&memcpyDTadaptive, -1}, + {"CcopyAsGrowable", (DL_FUNC)©AsGrowable, -1}, + {"Cfrolladapt", (DL_FUNC)&frolladapt, -1}, + {"Cis_direct_child", (DL_FUNC)&is_direct_child, -1}, + {NULL, NULL, 0}}; -static const -R_ExternalMethodDef externalMethods[] = { -{"Cfastmean", (DL_FUNC) &fastmean, -1}, -{NULL, NULL, 0} -}; +static const R_ExternalMethodDef externalMethods[] = { + {"Cfastmean", (DL_FUNC)&fastmean, -1}, + {NULL, NULL, 0}}; -static void setSizes(void) { - for (int i=0; i<100; ++i) { r_type_sizes[i]=0; r_type_order[i]=0; } +static void setSizes(void) +{ + for (int i = 0; i < 100; ++i) + { + r_type_sizes[i] = 0; + r_type_order[i] = 0; + } // only these types are currently allowed as column types : - r_type_sizes[LGLSXP] = sizeof(int); r_type_order[LGLSXP] = 0; - r_type_sizes[RAWSXP] = sizeof(Rbyte); r_type_order[RAWSXP] = 1; - r_type_sizes[INTSXP] = sizeof(int); r_type_order[INTSXP] = 2; // integer and factor - r_type_sizes[REALSXP] = sizeof(double); r_type_order[REALSXP] = 3; // numeric and integer64 - r_type_sizes[CPLXSXP] = sizeof(Rcomplex); r_type_order[CPLXSXP] = 4; - r_type_sizes[STRSXP] = sizeof(SEXP *); r_type_order[STRSXP] = 5; - r_type_sizes[VECSXP] = sizeof(SEXP *); r_type_order[VECSXP] = 6; // list column - if (sizeof(char *)>8) error(_("Pointers are %zu bytes, greater than 8. We have not tested on any architecture greater than 64bit yet."), sizeof(char *)); + r_type_sizes[LGLSXP] = sizeof(int); + r_type_order[LGLSXP] = 0; + r_type_sizes[RAWSXP] = sizeof(Rbyte); + r_type_order[RAWSXP] = 1; + r_type_sizes[INTSXP] = sizeof(int); + r_type_order[INTSXP] = 2; // integer and factor + r_type_sizes[REALSXP] = sizeof(double); + r_type_order[REALSXP] = 3; // numeric and integer64 + r_type_sizes[CPLXSXP] = sizeof(Rcomplex); + r_type_order[CPLXSXP] = 4; + r_type_sizes[STRSXP] = sizeof(SEXP *); + r_type_order[STRSXP] = 5; + r_type_sizes[VECSXP] = sizeof(SEXP *); + r_type_order[VECSXP] = 6; // list column + if (sizeof(char *) > 8) + error(_("Pointers are %zu bytes, greater than 8. We have not tested on any architecture greater than 64bit yet."), sizeof(char *)); // One place we need the largest sizeof is the working memory malloc in reorder.c } @@ -189,67 +198,95 @@ void attribute_visible R_init_data_table(DllInfo *info) // C exported routines // must be also listed in inst/include/datatableAPI.h // for end user documentation see ?cdt - R_RegisterCCallable("data.table", "DT_subsetDT", (DL_FUNC) &subsetDT); + R_RegisterCCallable("data.table", "DT_subsetDT", (DL_FUNC)&subsetDT); R_registerRoutines(info, NULL, callMethods, NULL, externalMethods); R_useDynamicSymbols(info, FALSE); setSizes(); const char *msg = _("... failed. Please forward this message to maintainer('data.table')."); - if ((int)NA_INTEGER != (int)INT_MIN) error(_("Checking NA_INTEGER [%d] == INT_MIN [%d] %s"), NA_INTEGER, INT_MIN, msg); - if ((int)NA_INTEGER != (int)NA_LOGICAL) error(_("Checking NA_INTEGER [%d] == NA_LOGICAL [%d] %s"), NA_INTEGER, NA_LOGICAL, msg); - if (sizeof(int) != 4) error(_("Checking sizeof(%s) [%zu] is %d %s"), "int", sizeof(int), 4, msg); - if (sizeof(double) != 8) error(_("Checking sizeof(%s) [%zu] is %d %s"), "double", sizeof(double), 8, msg); // 8 on both 32bit and 64bit + if ((int)NA_INTEGER != (int)INT_MIN) + error(_("Checking NA_INTEGER [%d] == INT_MIN [%d] %s"), NA_INTEGER, INT_MIN, msg); + if ((int)NA_INTEGER != (int)NA_LOGICAL) + error(_("Checking NA_INTEGER [%d] == NA_LOGICAL [%d] %s"), NA_INTEGER, NA_LOGICAL, msg); + if (sizeof(int) != 4) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "int", sizeof(int), 4, msg); + if (sizeof(double) != 8) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "double", sizeof(double), 8, msg); // 8 on both 32bit and 64bit // alignof not available in C99: if (alignof(double) != 8) error(_("Checking alignof(double) [%lu] is 8 %s"), alignof(double), msg); // 8 on both 32bit and 64bit - if (sizeof(long long) != 8) error(_("Checking sizeof(%s) [%zu] is %d %s"), "long long", sizeof(long long), 8, msg); - if (sizeof(char *) != 4 && sizeof(char *) != 8) error(_("Checking sizeof(pointer) [%zu] is 4 or 8 %s"), sizeof(char *), msg); - if (sizeof(SEXP) != sizeof(char *)) error(_("Checking sizeof(SEXP) [%zu] == sizeof(pointer) [%zu] %s"), sizeof(SEXP), sizeof(char *), msg); - if (sizeof(uint64_t) != 8) error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint64_t", sizeof(uint64_t), 8, msg); - if (sizeof(int64_t) != 8) error(_("Checking sizeof(%s) [%zu] is %d %s"), "int64_t", sizeof(int64_t), 8, msg); - if (sizeof(signed char) != 1) error(_("Checking sizeof(%s) [%zu] is %d %s"), "signed char", sizeof(signed char), 1, msg); - if (sizeof(int8_t) != 1) error(_("Checking sizeof(%s) [%zu] is %d %s"), "int8_t", sizeof(int8_t), 1, msg); - if (sizeof(uint8_t) != 1) error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint8_t", sizeof(uint8_t), 1, msg); - if (sizeof(int16_t) != 2) error(_("Checking sizeof(%s) [%zu] is %d %s"), "int16_t", sizeof(int16_t), 2, msg); - if (sizeof(uint16_t) != 2) error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint16_t", sizeof(uint16_t), 2 ,msg); + if (sizeof(long long) != 8) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "long long", sizeof(long long), 8, msg); + if (sizeof(char *) != 4 && sizeof(char *) != 8) + error(_("Checking sizeof(pointer) [%zu] is 4 or 8 %s"), sizeof(char *), msg); + if (sizeof(SEXP) != sizeof(char *)) + error(_("Checking sizeof(SEXP) [%zu] == sizeof(pointer) [%zu] %s"), sizeof(SEXP), sizeof(char *), msg); + if (sizeof(uint64_t) != 8) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint64_t", sizeof(uint64_t), 8, msg); + if (sizeof(int64_t) != 8) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "int64_t", sizeof(int64_t), 8, msg); + if (sizeof(signed char) != 1) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "signed char", sizeof(signed char), 1, msg); + if (sizeof(int8_t) != 1) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "int8_t", sizeof(int8_t), 1, msg); + if (sizeof(uint8_t) != 1) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint8_t", sizeof(uint8_t), 1, msg); + if (sizeof(int16_t) != 2) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "int16_t", sizeof(int16_t), 2, msg); + if (sizeof(uint16_t) != 2) + error(_("Checking sizeof(%s) [%zu] is %d %s"), "uint16_t", sizeof(uint16_t), 2, msg); - SEXP tmp = PROTECT(allocVector(INTSXP,2)); - if (LENGTH(tmp)!=2) error(_("Checking LENGTH(allocVector(INTSXP,2)) [%d] is 2 %s"), LENGTH(tmp), msg); + SEXP tmp = PROTECT(allocVector(INTSXP, 2)); + if (LENGTH(tmp) != 2) + error(_("Checking LENGTH(allocVector(INTSXP,2)) [%d] is 2 %s"), LENGTH(tmp), msg); UNPROTECT(1); // According to IEEE (http://en.wikipedia.org/wiki/IEEE_754-1985#Zero) we can rely on 0.0 being all 0 bits. // But check here anyway just to be sure, just in case this answer is right (http://stackoverflow.com/a/2952680/403310). int i = 314; memset(&i, 0, sizeof(i)); - if (i != 0) error(_("Checking memset(&i,0,sizeof(int)); i == (int)0 %s"), msg); + if (i != 0) + error(_("Checking memset(&i,0,sizeof(int)); i == (int)0 %s"), msg); unsigned int ui = 314; memset(&ui, 0, sizeof(ui)); - if (ui != 0) error(_("Checking memset(&ui, 0, sizeof(unsigned int)); ui == (unsigned int)0 %s"), msg); + if (ui != 0) + error(_("Checking memset(&ui, 0, sizeof(unsigned int)); ui == (unsigned int)0 %s"), msg); double d = 3.14; memset(&d, 0, sizeof(d)); - if (d != 0.0) error(_("Checking memset(&d, 0, sizeof(double)); d == (double)0.0 %s"), msg); + if (d != 0.0) + error(_("Checking memset(&d, 0, sizeof(double)); d == (double)0.0 %s"), msg); long double ld = 3.14; memset(&ld, 0, sizeof(ld)); - if (ld != 0.0) error(_("Checking memset(&ld, 0, sizeof(long double)); ld == (long double)0.0 %s"), msg); + if (ld != 0.0) + error(_("Checking memset(&ld, 0, sizeof(long double)); ld == (long double)0.0 %s"), msg); // Check unsigned cast used in fread.c. This isn't overflow/underflow, just cast. - if ((uint_fast8_t)('0'-'/') != 1) error(_("Unlike the very common case, e.g. ASCII, the character '/' is not just before '0'.")); - if ((uint_fast8_t)('/'-'0') < 10) error(_("The C expression (uint_fast8_t)('/'-'0')<10 is true. Should be false.")); - if ((uint_fast8_t)(':'-'9') != 1) error(_("Unlike the very common case, e.g. ASCII, the character ':' is not just after '9'.")); - if ((uint_fast8_t)('9'-':') < 10) error(_("The C expression (uint_fast8_t)('9'-':')<10 is true. Should be false.")); + if ((uint_fast8_t)('0' - '/') != 1) + error(_("Unlike the very common case, e.g. ASCII, the character '/' is not just before '0'.")); + if ((uint_fast8_t)('/' - '0') < 10) + error(_("The C expression (uint_fast8_t)('/'-'0')<10 is true. Should be false.")); + if ((uint_fast8_t)(':' - '9') != 1) + error(_("Unlike the very common case, e.g. ASCII, the character ':' is not just after '9'.")); + if ((uint_fast8_t)('9' - ':') < 10) + error(_("The C expression (uint_fast8_t)('9'-':')<10 is true. Should be false.")); // Variables rather than #define for NA_INT64 to ensure correct usage; i.e. not casted NA_INT64_LL = LLONG_MIN; NA_INT64_D = LLtoD(NA_INT64_LL); - if (NA_INT64_LL != DtoLL(NA_INT64_D)) error(_("Conversion of NA_INT64 via double failed %"PRId64"!=%"PRId64), (int64_t)NA_INT64_LL, (int64_t)DtoLL(NA_INT64_D)); + if (NA_INT64_LL != DtoLL(NA_INT64_D)) + error(_("Conversion of NA_INT64 via double failed %" PRId64 "!=%" PRId64), (int64_t)NA_INT64_LL, (int64_t)DtoLL(NA_INT64_D)); // LLONG_MIN when punned to double is the sign bit set and then all zeros in exponent and significand i.e. -0.0 // That's why we must never test for NA_INT64_D using == in double type. Must always DtoLL and compare long long types. // Assigning NA_INT64_D to a REAL is ok however. - if (NA_INT64_D != 0.0) error(_("NA_INT64_D (negative -0.0) is not == 0.0.")); - if (NA_INT64_D != -0.0) error(_("NA_INT64_D (negative -0.0) is not ==-0.0.")); - if (ISNAN(NA_INT64_D)) error(_("ISNAN(NA_INT64_D) is TRUE but should not be")); - if (isnan(NA_INT64_D)) error(_("isnan(NA_INT64_D) is TRUE but should not be")); + if (NA_INT64_D != 0.0) + error(_("NA_INT64_D (negative -0.0) is not == 0.0.")); + if (NA_INT64_D != -0.0) + error(_("NA_INT64_D (negative -0.0) is not ==-0.0.")); + if (ISNAN(NA_INT64_D)) + error(_("ISNAN(NA_INT64_D) is TRUE but should not be")); + if (isnan(NA_INT64_D)) + error(_("isnan(NA_INT64_D) is TRUE but should not be")); - NA_CPLX.r = NA_REAL; // NA_REAL is defined as R_NaReal which is not a strict constant and thus initializer {NA_REAL, NA_REAL} can't be used in .h - NA_CPLX.i = NA_REAL; // https://github.com/Rdatatable/data.table/pull/3689/files#r304117234 + NA_CPLX.r = NA_REAL; // NA_REAL is defined as R_NaReal which is not a strict constant and thus initializer {NA_REAL, NA_REAL} can't be used in .h + NA_CPLX.i = NA_REAL; // https://github.com/Rdatatable/data.table/pull/3689/files#r304117234 setNumericRounding(PROTECT(ScalarInteger(0))); // #1642, #1728, #1463, #485 UNPROTECT(1); @@ -258,29 +295,30 @@ void attribute_visible R_init_data_table(DllInfo *info) // Following R-exts 5.9.4; paragraph and example starting "Using install ..." // either use PRINTNAME(install()) or R_PreserveObject(mkChar()) here. char_integer64 = PRINTNAME(install("integer64")); - char_ITime = PRINTNAME(install("ITime")); - char_IDate = PRINTNAME(install("IDate")); - char_Date = PRINTNAME(install("Date")); // used for IDate too since IDate inherits from Date - char_POSIXct = PRINTNAME(install("POSIXct")); - char_POSIXt = PRINTNAME(install("POSIXt")); - char_UTC = PRINTNAME(install("UTC")); - char_nanotime = PRINTNAME(install("nanotime")); - char_starts = PRINTNAME(sym_starts = install("starts")); - char_lens = PRINTNAME(install("lens")); - char_indices = PRINTNAME(install("indices")); - char_allLen1 = PRINTNAME(install("allLen1")); - char_allGrp1 = PRINTNAME(install("allGrp1")); - char_factor = PRINTNAME(install("factor")); - char_ordered = PRINTNAME(install("ordered")); + char_ITime = PRINTNAME(install("ITime")); + char_IDate = PRINTNAME(install("IDate")); + char_Date = PRINTNAME(install("Date")); // used for IDate too since IDate inherits from Date + char_POSIXct = PRINTNAME(install("POSIXct")); + char_POSIXt = PRINTNAME(install("POSIXt")); + char_UTC = PRINTNAME(install("UTC")); + char_nanotime = PRINTNAME(install("nanotime")); + char_starts = PRINTNAME(sym_starts = install("starts")); + char_lens = PRINTNAME(install("lens")); + char_indices = PRINTNAME(install("indices")); + char_allLen1 = PRINTNAME(install("allLen1")); + char_allGrp1 = PRINTNAME(install("allGrp1")); + char_factor = PRINTNAME(install("factor")); + char_ordered = PRINTNAME(install("ordered")); char_datatable = PRINTNAME(install("data.table")); char_dataframe = PRINTNAME(install("data.frame")); - char_NULL = PRINTNAME(install("NULL")); + char_NULL = PRINTNAME(install("NULL")); char_maxString = PRINTNAME(install("\xFF\xFF\xFF\xFF\xFF\xFF\xFF\xFF")); - char_AsIs = PRINTNAME(install("AsIs")); + char_AsIs = PRINTNAME(install("AsIs")); - if (TYPEOF(char_integer64) != CHARSXP) { + if (TYPEOF(char_integer64) != CHARSXP) + { // checking one is enough in case of any R-devel changes - error(_("PRINTNAME(install(\"integer64\")) has returned %s not %s"), type2char(TYPEOF(char_integer64)), type2char(CHARSXP)); // # nocov + error(_("PRINTNAME(install(\"integer64\")) has returned %s not %s"), type2char(TYPEOF(char_integer64)), type2char(CHARSXP)); // # nocov } // create commonly used symbols, same as R_*Symbol but internal to DT @@ -290,11 +328,11 @@ void attribute_visible R_init_data_table(DllInfo *info) // avoids the gc without needing an extra PROTECT and immediate UNPROTECT after the setAttrib which would // look odd (and devs in future might be tempted to remove them). Avoiding passing install() to API calls // keeps the code neat and readable. Also see grep's added to CRAN_Release.cmd to find such calls. - sym_sorted = install("sorted"); - sym_index = install("index"); - sym_BY = install(".BY"); + sym_sorted = install("sorted"); + sym_index = install("index"); + sym_BY = install(".BY"); sym_maxgrpn = install("maxgrpn"); - sym_anyna = install("anyna"); + sym_anyna = install("anyna"); sym_anyinfnan = install("anyinfnan"); sym_anynotascii = install("anynotascii"); sym_anynotutf8 = install("anynotutf8"); @@ -313,7 +351,8 @@ void attribute_visible R_init_data_table(DllInfo *info) avoid_openmp_hang_within_fork(); } -inline long long DtoLL(double x) { +inline long long DtoLL(double x) +{ // Type punning such as // *(long long *)&REAL(column)[i] // is undefined by C standards. This may have been the cause of 1.10.2 failing on 31 Jan 2017 @@ -324,27 +363,38 @@ inline long long DtoLL(double x) { // where sizeof(int64_t)==sizeof(double)==8 is checked. // Endianness should not matter because whether big or little, endianness is the same // inside this process, and the two types are the same size. - union {double d; int64_t i64;} u; // not static, inline instead + union + { + double d; + int64_t i64; + } u; // not static, inline instead u.d = x; return (long long)u.i64; } -inline double LLtoD(long long x) { - union {double d; int64_t i64;} u; +inline double LLtoD(long long x) +{ + union + { + double d; + int64_t i64; + } u; u.i64 = (int64_t)x; return u.d; } -int GetVerbose(void) { +int GetVerbose(void) +{ // don't call repetitively; save first in that case SEXP opt = GetOption1(sym_verbose); - if ((!isLogical(opt) && !isInteger(opt)) || LENGTH(opt)!=1 || INTEGER(opt)[0]==NA_INTEGER) + if ((!isLogical(opt) && !isInteger(opt)) || LENGTH(opt) != 1 || INTEGER(opt)[0] == NA_INTEGER) error(_("verbose option must be length 1 non-NA logical or integer")); return INTEGER(opt)[0]; } // # nocov start -SEXP hasOpenMP(void) { +SEXP hasOpenMP(void) +{ #if defined(_OPENMP) // gcc build of libomp @@ -356,20 +406,22 @@ SEXP hasOpenMP(void) { // no OpenMP support detected return ScalarInteger(0); #endif - } // # nocov end -extern int *_Last_updated; // assign.c +extern int *_Last_updated; // assign.c -SEXP initLastUpdated(SEXP var) { - if (!isInteger(var) || LENGTH(var)!=1) error(_(".Last.updated in namespace is not a length 1 integer")); +SEXP initLastUpdated(SEXP var) +{ + if (!isInteger(var) || LENGTH(var) != 1) + error(_(".Last.updated in namespace is not a length 1 integer")); _Last_updated = INTEGER(var); return R_NilValue; } -SEXP dllVersion(void) { +SEXP dllVersion(void) +{ // .onLoad calls this and checks the same as packageVersion() to ensure no R/C version mismatch, #3056 - return(ScalarString(mkChar("1.18.0"))); + return (ScalarString(mkChar("1.18.99"))); }