Learn R Programming

rlang (version 1.0.1)

cnd_type: What type is a condition?

Description

Use cnd_type() to check what type a condition is.

Usage

cnd_type(cnd)

Arguments

cnd

A condition object.

Value

A string, either "condition", "message", "warning", "error" or "interrupt".

Examples

Run this code
# NOT RUN {
cnd_type(catch_cnd(abort("Abort!")))
cnd_type(catch_cnd(interrupt()))
# }

Run the code above in your browser using DataLab