These functions are equivalent to base functions
base::message(), but the
makes it easy to create subclassed conditions. They also don't
include call information by default. This saves you from typing
call. = FALSE to make error messages cleaner within package
abort(msg, type = NULL, call = FALSE) warn(msg, type = NULL, call = FALSE) inform(msg, type = NULL, call = FALSE)
A message to display.
Subclass of the condition to signal.
Whether to display the call.
abort() signals a critical
condition and interrupts execution by jumping to top level (see
rst_abort()). Only a handler of the relevant type can prevent
this jump by making another jump to a different target on the stack
inform() both have the side effect of displaying a
message. These messages will not be displayed if a handler
transfers control. Transfer can be achieved by establishing an
exiting handler that transfers control to
this case, the current function stops and execution resumes at the
point where handlers were established.
Since it is often desirable to continue normally after a message or
inform() (and their base R equivalent)
establish a muffle restart where handlers can jump to prevent the
message from being displayed. Execution resumes normally after
rst_muffle() to jump to a muffling restart, and the
muffle argument of
inplace() for creating a muffling handler.