You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Activate + apply some linters
* Updated paste_linter in dev version of lintr
* trailing whitespace missed last time
* Different error message from rep_len()
* one more
* Also knock out '<<-' usage
if (!bysameorder&&keyby&&!length(irows) && isTRUE(getOption("datatable.use.index"))) {
826
826
# TODO: could be allowed if length(irows)>1 but then the index would need to be squashed for use by uniqlist, #3062
827
827
# find if allbyvars is leading subset of any of the indices; add a trailing "__" to fix #3498 where a longer column name starts with a shorter column name
warningf('Different branches of j expression produced different auto-named columns: %s; using the most "last" names. If this was intentional (e.g., you know only one branch will ever be used in a given query because the branch is controlled by a function argument), please (1) pull this branch out of the call; (2) explicitly provide missing defaults for each branch in all cases; or (3) use the same name for each branch and re-name it in a follow-up call.', brackify(sprintf('%s!=%s', nm[idx], jvnames[idx])))
962
962
}
963
+
# nolint next: undesirable_operator_linter. Workaround is clunkier, though a bigger refactor could be considered.
963
964
jvnames<<-nm# TODO: handle if() list(a, b) else list(b, a) better
964
965
setattr(q, "names", NULL) # drops the names from the list so it's faster to eval the j for each group; reinstated at the end on the result.
if (!is.character(cols) || length(cols)<1L) stopf("Internal error. 'cols' should be character at this point in setkey; please report.") # nocov
79
79
80
-
newkey=paste0(cols, collapse="__")
80
+
newkey=paste(cols, collapse="__")
81
81
if (!any(indices(x) ==newkey)) {
82
82
if (verbose) {
83
83
tt= suppressMessages(system.time(o<- forderv(x, cols, sort=TRUE, retGrp=FALSE))) # system.time does a gc, so we don't want this always on, until refcnt is on by default in R
0 commit comments