You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- \code{axis.line.y.left}, \code{axis.line.y.right}). \code{axis.line.*.*} inherits from- \code{axis.line.*} which inherits from \code{axis.line}, which in turn inherits+ \code{axis.line.y.left}, \code{axis.line.y.right}). \verb{axis.line.*.*} inherits from+ \verb{axis.line.*} which inherits from \code{axis.line}, which in turn inherits
I think \code{} should be used here because axis.line.* is a symbol, not a part of code snippet. Though this doesn't seem a big issue (and I don't know well about what \verb{} is), I'm filing this issue just for notice. Please feel free to close if this is not a problem.
I think \code{} should be used here because axis.line.* is a symbol
\code{} must be valid R code, and axis.line.* is not, so according to the Rd rules, it has to be \verb{}. Not that it matters much for the output, because both \verb{} and \code{} are displayed the same exact way AFAIK.
I'm not sure if Writing R Extension explicitly says so. In my understanding, the R code on Rd is not necessarily valid except when it's intended to run as it says about \examples{}:
Text included in \dontrun is indicated by comments in the processed help files: it need not be valid R code but the escapes must still be used for %, \ and unpaired braces as in other ‘verbatim’ text.
I'm also not sure if this applies \code{} or not, though.
I'm not sure if Writing R Extension explicitly says so. In my understanding, the R code on Rd is not necessarily valid except when it's intended to run as it says about \examples{}:
Basically in that document "R-like" means syntactically valid R code. This holds for \examples{}, \usage{}, etc., and \code{} as well. But R CMD check does not enforce it for \code{} because many packages misuse it. That is my understanding. :)
Activity
lionel- commentedon Nov 18, 2019
See also #971.
gaborcsardi commentedon Nov 18, 2019
\code{}must be valid R code, andaxis.line.*is not, so according to the Rd rules, it has to be\verb{}. Not that it matters much for the output, because both\verb{}and\code{}are displayed the same exact way AFAIK.yutannihilation commentedon Nov 18, 2019
I'm not sure if Writing R Extension explicitly says so. In my understanding, the R code on Rd is not necessarily valid except when it's intended to run as it says about
\examples{}:I'm also not sure if this applies
\code{}or not, though.gaborcsardi commentedon Nov 18, 2019
It is in Table 3: https://developer.r-project.org/parseRd.pdf
yutannihilation commentedon Nov 18, 2019
Thanks, probably it's just I don't understand the terminologies. Sorry for the noise...
gaborcsardi commentedon Nov 18, 2019
Basically in that document "R-like" means syntactically valid R code. This holds for
\examples{},\usage{}, etc., and\code{}as well. ButR CMD checkdoes not enforce it for\code{}because many packages misuse it. That is my understanding. :)yutannihilation commentedon Nov 18, 2019
Ah, got it! I was wondering why R CMD check didn't bite us if it's not valid... Then I totally agree with you. Closing this now. Thanks!