-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Thanks for developing this great package!
I'm using @autoglobal in a package that uses {data.table}. {data.table} syntax allows list() to be replaced with .(), which is detected by R CMD check (devtools::check()) as:
checking R code for possible problems ... NOTE
foo: no visible global function definition for ‘.’
Undefined global functions or variables:
.Here is an example function that would produce this check note:
#' Subset a `<data.table>`
#'
#' @param x A `<data.table>` including columns `$a` and `$b`.
#'
#' @return A `<data.table>`
#' @autoglobal
#' @export
#'
#' @examples
#' if (requireNamespace("data.table", quietly = TRUE)) {
#' dt <- data.table::data.table(a = 1:10, b = 11:20, c = letters[1:10])
#' foo(x = dt)
#' }
foo <- function(x) {
x[, .(a, b)]
}It would be great if @autoglobal could also add . to the globals.R file.
Metadata
Metadata
Assignees
Labels
No labels