Skip to content

Commit a74ed38

Browse files
committed
Merge pull request #344 from fplaza/char-converter-patch
Fix conversion from char to string (closes #343)
2 parents e0ea6ed + bbe2bbe commit a74ed38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

inst/include/Rcpp/vector/converter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ namespace internal {
6060

6161
static SEXP get(const char& input){
6262
RCPP_DEBUG( "string_element_converter::get< char >()" )
63-
return Rf_mkChar( &input ) ;
63+
return Rf_mkCharLen( &input, 1 ) ;
6464
}
6565

6666
// assuming a CHARSXP

0 commit comments

Comments
 (0)