Closed djhbs closed 11 months ago
That's because a = character(0)
is an assignment expression just like a <- character(0)
. And you are injecting this whole assignment as individual argument.
If you want to pass names, do it via the names of the list of expressions, e.g.
exprs <- c(a = "character(0)", b = "integer()", c = "double()")
# Or equivalently:
exprs <- list(a = quote(character(0)), b = quote(integer()), c = quote(double()))
Thank you so much for your detailed explanation.
Hi, thank you very much for help.
In the below example, the
rlang::qq_show
show the right code:tibble::tibble(a = character(0), b = integer(), c = double())
but the execution does not return right variable names, only the right type.
For first variable, the right name should be
a
nota = character(0)
I am not sure I use the function wrongly, but the result is strange.