Implement .null argument#217
Implement .null argument#217jimhester merged 3 commits intotidyverse:masterfrom echasnovski:null-arg-84
.null argument#217Conversation
|
Thanks for working on this! However the PR is not currently quite the behavior we want. If If I think we have also decided we are going to change the default behavior of |
- If `character()`: return `character()` if there is any `NULL` element. - If `NULL`: drop any `NULL` elements (as `paste0()`). - Else: replace `NULL` with `.null`.
|
Added described behavior but didn't change the default value to This introduces one peculiar edge case. What should be the output of Currently I decided to stick with " |
|
Also a question about a code I stumbled here. Is there a need for Git history shows that it was altered for two reasons: in bcfaf72 to account for lazy loading and in 9cb52dd to fix when last expression is |
|
It seems the test cases for that PR were not added when it was committed manually. Could you add them and verify removing the conditional does not break the behavior? |
|
Yep, they are present. Removing that check doesn't break anything, both on master and in this branch (as long as I'll remove this check here. |
Relevant tests are in "length 0 inputs produce length 0 outputs", ones which have `NULL` values. They don't break if check is removed.
|
Thanks for working on this! |
This PR add
.nullargument toglue()andglue_data(). As it was suggested in comment, this fixes #84.