Skip to content
Prev 9530 / 10988 Next

[Rcpp-devel] Translate during coercion from String to Symbol?

Hi


It seems that R silently assumes that symbols are encoded in the native 
encoding. However, no attempt to reencode is made in Rf_installChar(), 
which is called by Symbol::Symbol(SEXP) in the CHARSXP case. I wonder if 
Rcpp should be calling Rf_install(Rf_translateChar(x)) instead, to 
ensure proper encoding.

Unfortunately, the better and faster Rf_installTrChar() isn't (yet) part 
of the API.


Best regards

Kirill