Skip to contents

Does an Object Inherit from "try-error"?

Usage

isTryError(x)

Arguments

x

R object

Value

logical of length one, TRUE if x inherits from "try-error", otherwise FALSE

Examples

result <- try(stop("Stop!"), silent = TRUE)
isTryError(result) # TRUE
#> [1] TRUE