Skip to main content

has_r_invalid_name

Function has_r_invalid_name 

Source
pub fn has_r_invalid_name(cst: &SyntaxNode) -> bool
Expand description

Whether the tree contains a name R’s lexer rejects but arity’s more lenient one accepts as an ordinary identifier.

A _-leading name errors in R’s lexer, with one exception: a lone _ used as the native-pipe placeholder, valid only inside a |> pipeline (a _-leading name of length ≥ 2 is never valid). A zero-length backquoted name `` errors at parse time (“attempt to use zero-length variable name”); any non-empty backquoted name is valid.