1setGeneric("unique") 2 3nil <- NULL # see if we can use '::' on it 4 5Cfun <- function(x) { 6 new("classA", # classA was imported from 'pkgA' 7 cbind(x, b=x+2)) 8} 9 10## Pkg 'ecd' had 11## setClassUnion("numericMpfr", c("numeric", "mpfr", "mpfrArray")) 12## 13## which gave an 'R CMD INSTALL' warning with Rmpfr 0.7-2 14' 15** byte-compile and prepare package for lazy loading 16Warning: subclass "summaryMpfr" of class "mpfr" is not local and cannot be updated for new inheritance information; consider setClassUnion() 17' 18## 'Rmpfr' there corresponds to 'pkgA' here; 19## ---- class "mpfr" to "classA" here, 20## class "summaryMpfr" to "classApp" here .. : 21setClassUnion("numericA", c("numeric", "classA", "matrix")) 22 23