Re: [R] modify the imported version of a function

2016-12-19 Thread Benjamin Tyner
Figured it out...in case it is useful to others: > library(lint) > lint.enclos <- parent.env(asNamespace("lint")) > stopifnot(all(c("perl", "regex") %in% ls(lint.enclos))) > lint.enclos$perl function (pattern) { message("perl is deprecated. Please use regexp instead")

[R] modify the imported version of a function

2016-12-16 Thread Benjamin Tyner
Hi I saw on the assignInNamespace help page, that it changes "the copy in the namespace, but not any copies already exported from the namespace, in particular an object of that name in the package (if already attached) and any copies already imported into other namespaces." So now I'm wonder