purrr
purrr copied to clipboard
Mention `walk2()` in `map2.R` documentation Value section
The documentation in map2.R
inherits from map.R
for the Value section:
#' @inherit map return
This is okay for the first 3 bullets. However, for the final bullet, the map2.R
documentation still refers to walk()
instead of walk2()
:
walk() returns the input
.x
(invisibly). This makes it easy to use in a pipe. The return value of.f()
is ignored.
I think it's important to specify that walk2()
returns the first of its two arguments, (fortunately still named .x
). It's a small change, but it clarifies behavior that could be potentially confusing.