[Rcpp-devel] Translate during coercion from String to Symbol?
edd at debian.org
Sun Feb 19 00:18:51 CET 2017
On 19 February 2017 at 00:02, Kirill Müller wrote:
| 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.
That's entirely possible.
As you seem to know what code parts you looked at, would you mind sharing
that information so that we know better exactly _what_ you are talking about?
| Unfortunately, the better and faster Rf_installTrChar() isn't (yet) part
| of the API.
Worst case we mock, copy or reimplement it. Ultimately there may well be
changes coming down the road because of the Leeper + Cotton i18n project.
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
More information about the Rcpp-devel