Re: [Rcpp-devel] named and default arguments in exposed C++ classes

2014-03-05 Thread Dirk Eddelbuettel
On 5 March 2014 at 16:26, Andreas Prescher wrote: | Hello, | | I wrote a R package using Rcpp (0.10.4) modules | to expose my C++ classes. | | All works fine, but for convenient using from R, | it would be great to use the class methods with | named arguments and default arguments. | | At the m

[Rcpp-devel] named and default arguments in exposed C++ classes

2014-03-05 Thread Andreas Prescher
Hello, I wrote a R package using Rcpp (0.10.4) modules to expose my C++ classes. All works fine, but for convenient using from R, it would be great to use the class methods with named arguments and default arguments. At the moment I have to use all class methods as declared in the corresponding

Re: [Rcpp-devel] Underflow of unsigned integers

2014-03-05 Thread Dirk Eddelbuettel
On 5 March 2014 at 12:07, Xavier Robin wrote: | Given the following function: | > // [[Rcpp::export]] | > void test_size_t(size_t s) { | > std::cout << s << std::endl; | > } | compiled with sourceCpp or in a package, I get the following behavior: | > > test_size_t(-1) | > 18446744073709551615

[Rcpp-devel] Underflow of unsigned integers

2014-03-05 Thread Xavier Robin
Given the following function: // [[Rcpp::export]] void test_size_t(size_t s) { std::cout << s << std::endl; } compiled with sourceCpp or in a package, I get the following behavior: > test_size_t(-1) 18446744073709551615 Of course this is not what I want. I would be OK with the value being