escape_rd_for_md() replaces fragile Rd tags with placeholders, to avoid
interpreting them as markdown. unescape_rd_for_md() puts the original
text back in place of the placeholders after the markdown parsing is done.
The fragile tags are listed in escaped_for_md. A fragile tag is
protected together with all of its brace arguments, so markdown is never
interpreted inside them.
escape_rd_for_md(text)unescape_rd_for_md(rd_text, esc_text)
escape_rd_for_md: a "safe" version of the input text, where
each fragile Rd tag is replaced by a placeholder. The
original text is added as an attribute for each placeholder.
unescape_rd_for_md: the original Rd text.
Input text. Potentially contains Rd and/or markdown markup.
The markdown parsed and interpreted text.
The original escaped text from
escape_rd_for_md().