Skip to content
Prev 5562 / 63421 Next

argument names in generic print functions (PR#955)

Hello,

I think this is a bug, although it is possible that I'm doind something
silly.

I want to be able to determine the argument name for variables passed to
a generic print function

suppose we have

print.foo <- function(x, ...)
{
nm<-deparse(substitute(x))
cat("param name is ", nm, "\n")
}

d<-structure(1, class="foo")

Under R-1.2.[2,3]
param name is  d
param name is  structure(1, class = "foo") 


Under Splus 3.4 the responses are
param name is  d
param name is  d 


If I'm going about this the wrong way then please let me know.

Thanks