tidyverse / dtplyr

Data table backend for dplyr
https://dtplyr.tidyverse.org
Other
670 stars 57 forks source link

`dt_squash` anonymous functions #365

Closed markfairbanks closed 2 years ago

markfairbanks commented 2 years ago

Closes #362

eutwt commented 2 years ago

This fixes the issue outside of across, but made me realize I didn't handle #288 right, because anonymous functions in across don't get dplyr verbs translated

lazy_dt(tibble(y = 1)) %>% 
  mutate(across(y, function(x) x + n()))
markfairbanks commented 2 years ago

Ah for some reason I assumed that across() .fns would be using the same dt_squash() path but looks like it's different.

Might be easier to merge this one and deal with the across() issue separately. That work for you @eutwt?

eutwt commented 2 years ago

Yeah I think that makes sense