Skip to main content

escape_rd_usage

Function escape_rd_usage 

Source
fn escape_rd_usage(text: &str) -> String
Expand description

Escape text for Rd usage/examples blocks (R code).

In R code sections, only % needs escaping (it’s still an Rd comment character). Braces and backslashes are valid R syntax and should be left alone so the code remains valid.