Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- stop <- function(..., call. = FALSE, domain = NULL){
- base::stop(..., call. = call., domain = domain);
- }
- > stop(simpleError("foo"))
- Error: foo
- In addition: Warning message:
- In base::stop(..., call. = call., domain = domain) :
- additional arguments ignored in stop()
- if (length(args) == 1L && inherits(args[[1L]], "condition")) {
- ....
- if (nargs() > 1L) # give the warning
- stop(simpleError('achtung!'))
- # Error: achtung!
- stop(simpleError('achtung!'), call.=F) # gives the warning
- # Error: achtung!
- # In addition: Warning message:
- # In stop(simpleError("achtung!"), call. = F) :
- # additional arguments ignored in stop()
- stop(simpleError('achtung!', call=call('f')))
- # Error in f() : achtung!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement