These functions are deprecated, please use is_call()
and its n
argument instead.
Arguments
- x
An object to test. Formulas and quosures are treated literally.
- name
An optional name that the call should match. It is passed to
sym()
before matching. This argument is vectorised and you can supply a vector of names to match. In this case,is_call()
returnsTRUE
if at least one name matches.- n
An optional number of arguments that the call should match.
- ns
The namespace of the call. If
NULL
, the namespace doesn't participate in the pattern-matching. If an empty string""
andx
is a namespaced call,is_call()
returnsFALSE
. If any other string,is_call()
checks thatx
is namespaced withinns
.Can be a character vector of namespaces, in which case the call has to match at least one of them, otherwise
is_call()
returnsFALSE
.