-
Notifications
You must be signed in to change notification settings - Fork 420
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More generic functions #1101
base: main
Are you sure you want to change the base?
More generic functions #1101
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good — one comment about the position of ...
and then can you please add a bullet to NEWS?
R/chop.R
Outdated
@@ -89,7 +96,13 @@ chop <- function(data, cols) { | |||
|
|||
#' @export | |||
#' @rdname chop | |||
unchop <- function(data, cols, keep_empty = FALSE, ptype = NULL) { | |||
unchop <- function(data, cols, keep_empty = FALSE, ptype = NULL, ...) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general, I think it's better to put the dots before the first optional argument. It's possible that a few people might have relied on partial or position based matching, but check_dots_used()
will catch that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In build_wider_spec()
I put the dots after names_from
and values_from
as they felt like main arguments and that's also how they were used in the test names_glue affects output names
Fixes #1071 .
With the recent effort of bringing tidyr verbs to
dtplyr
I guess it makes sense to make these functions generic now.