[Rcpp-devel] long long

Dirk Eddelbuettel edd at debian.org
Thu Sep 19 20:53:51 CEST 2013


On 19 September 2013 at 20:08, Romain Francois wrote:
| Alright, so with these settings -pedantic turns on -Wlong-long
| 
| I can disable them with -Wno-long-long
| 
| Can we detect gcc with a configure and set -Wno-long-long, is that allowed ?
| 
| Where in the CRAN policies does it say that -pedantic should be used ? I 
| did not find it.

Where does it say that CRAN Policies are fully specified and written out?  

Please just take my word for it based on a few years of dealing with Kurt and
CRAN, and / or experiment yourself with a small (new ?) package of yours. 

Because this will not fly I would prefer that the change be rolled back.

People who really need long long already have an easy hook:  -std=c++11

| We don't actually "compile" code that needs rcpp_long_long_type in Rcpp 
| (in the .cpp files), so I might have an idea to move this problem.
| 
| We could put this behind another define, like this:
| 
| #if defined(RCPP_LONG_LONG_SUPPORT)
| #if defined(__GNUC__) &&  defined(__LONG_LONG_MAX__)
|      __extension__ typedef long long int rcpp_long_long_type;
|      __extension__ typedef unsigned long long int rcpp_ulong_long_type;
|      #define RCPP_HAS_LONG_LONG_TYPES
| #endif
| #endif
| 
| so that Rcpp compiles fine, and if someone wants to use it, then in 
| their code thay can :
| 
| #define RCPP_LONG_LONG_SUPPORT
| #include <Rcpp.h>
| 
| On your machine with your settings, this no longer warns.

Sure, but this seems like is bike-shedding: A local variant already had this
by simply adding -std=c++11 as C++ post-1998 has long long types.  Now you
just renamed the handle, for no real tangible benefit.  I know this is
frustrating, and I don;t mean to be difficult.  But if we fight a fight with
CRAN, let's fight over C++11.  This issue here does not really matter.

And personally, I'd prefer a bit more stability in our core headers.  The
previous setting worked for a number of years.

Dirk

-- 
Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com


More information about the Rcpp-devel mailing list