register_dubious_syntaxes {doubt} | R Documentation |
To use a dubious syntax in a package, use this function in the definition of .onAttach
register_dubious_syntaxes(syntaxes)
syntaxes |
a character vector of the syntaxes to support |
## Not run:
# define your syntax as you would define a normal function
`?add> {x} : {y}` <- function(x, y) x + y
# register the syntax in your .onAttach definition
.onAttach <- function(libname, pkgname) {
doubt::register_dubious_syntaxes("?add> {x} : {y}")
invisible()
}
## End(Not run)