Skip to main content

rlang_format_error_arg

Function rlang_format_error_arg 

Source
extern "C" fn rlang_format_error_arg(arg: Sexp) -> *const c_char
Expand description

Format an argument name for error messages.

Signature: const char* rlang_format_error_arg(SEXP arg)

In real rlang, this calls R code format_arg(x) which wraps the arg name in backticks. We approximate: if the SEXP is a STRSXP of length 1, extract the string and wrap it in backticks.