Skip to content
Prev 41158 / 63421 Next

"\088" is legal syntax?

The CRAN package svMisc misuses it, using "\8" instead of "\10" or "\b":
 ./svMisc/R/progress.R:          backspaces <- paste(rep("\8", l3), collapse = "")

I noticed it when S+ emitted a warning when parsing that file:
  > p <- parse("svMisc/R/progress.R")
  Warning messages:
    The initial backslash is ignored in \8 -- not a recognized escape sequence.
          Use \\ to make a backslash in: parse("svMisc/R/progress.R")
(S+ parses the "\8" as "8", as the warning obliquly implies.)

I grepped through other CRAN sources for "\\0*8" and also found
  ./mvbutils/R/mvbutils.R:  rep.percent <- '\008'
S+ emits no warning for that but parses it as "", because it
considers the octal escape to stop at the first non-octal digit.

Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com