options(error = expression(NULL))
# don't stop on stop(.) << Use with CARE! >>
iter <- 12
if(iter > 10) stop("too many iterations")
tst1 <- function(...) stop("dummy error")
tst1(1:10, long, calling, expression)
tst2 <- function(...) stop("dummy error", call. = FALSE)
tst2(1:10, longcalling, expression, but.not.seen.in.Error)
options(error = NULL) # restore to default
Run the code above in your browser using DataLab