tidyverse / magrittr

Improve the readability of R code with the pipe
https://magrittr.tidyverse.org
Other
957 stars 157 forks source link

Switch to lazy implementation #218

Closed lionel- closed 4 years ago

lionel- commented 4 years ago

Branched from #216.

Adds named variants pipe_eager_lexical(), pipe_lazy_masking(), and pipe_nested() to easily experiment with the properties of three complementary pipe implementations.

Switch %>% to lazy evaluation in a mask, so that stop("foo") %>% try() works. No impact on reverse dependencies. This brings the pipe closer to the implementation that will likely be included in a future version of R.