[Rd] R_MakeExternalPtr 'tag' argument
Simon Urbanek
simon.urbanek at r-project.org
Sat Nov 14 14:43:04 CET 2015
On Nov 13, 2015, at 3:58 PM, William Dunlap <wdunlap at tibco.com> wrote:
> Most packages that use the R_MakeExternalPtr function use
> Rf_install("pkgSpecificString") for its 'tag' argument (if they don't use
> R_NilValue). A few use Rf_mkChar("pkgSpecificString").
>
> Is there any reason to prefer one over the other?
>
I think Luke is the definite authority, but IMHO using CHARSXP is illegal since you can only store CHARSXP in STRSXP. R-exts allows "ordinary R objects" so presumably mkString() would be legal.
Cheers,
Simon
More information about the R-devel
mailing list