reverse.list <- function(...) {
d <- dots(...)
list %()% rev(d)
}
reverse.list("a", b="bee", c="see")
named.list <- function(...) {
d <- dots(...)
list %()% d[names(d) != ""]
}
named.list(a=1, b=2*2, stop("this is not evaluated"))
Run the code above in your browser using DataLab