renkun-ken / pipeR

Multi-Paradigm Pipeline Implementation
Other
169 stars 39 forks source link

Not compatible with `...` #9

Closed renkun-ken closed 10 years ago

renkun-ken commented 10 years ago

A reproducible example:

library(pipeR)

fun1 <- function(x,...) {
  plot(x,col="red",...)
}

rnorm(100) %>% fun1(type="l")

fun2 <- function(n,...) {
  rnorm(n) %>% fun1(...)
}

fun2(10,type="l")

produces

Error in eval(expr, envir, enclos) : '...' used in an incorrect context
Called from: rnorm(n) %>% fun1(...)