[Rcpp-devel] RcppEigen questions

Dirk Eddelbuettel edd at debian.org
Sat Nov 19 04:17:18 CET 2011


On 18 November 2011 at 19:42, Dirk Eddelbuettel wrote:
| 2) I have never seen an idiom
| 
|       SomeType amc{a};
| 
|    using curly braces for initializers. I may be behind the times here.  Can
|    you point me to some documentation which shows this to be legit?

Hao and I continued this off-list for a bit more, and that is indeed legit
once you use '-std=c++0x' with a recent g++ version.  Eg I just tried

  std::vector<double> y{ 1.1, 2.2};

and this constructor-initialization form (which I hadn't seen, or forgotten
about) passes fine.

Too bad we can't yet use -std=c++0x on CRAN submissions....

Dirk

-- 
"Outside of a dog, a book is a man's best friend. Inside of a dog, it is too
dark to read." -- Groucho Marx


More information about the Rcpp-devel mailing list