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.



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.

Romain


Le 19/09/13 18:32, Dirk Eddelbuettel a écrit :

Darn. Romain's change look promising, but it seems that even with R-release I
get a bunch of warnings which would prevent this from going to CRAN.  Maybe
the status quo wasn't so bad after all.

Current SVN head as below. Ubuntu 13.03, 64bit. G++ 4.7.3 selected via CXX in
the file ~/.R/Makevars

Dirk

edd@max:~/svn/rcpp/pkg$ svn info
Path: .
Working Copy Root Path: /home/edd/svn/rcpp
URL: svn+ssh://[email protected]/svnroot/rcpp/pkg
Repository Root: svn+ssh://[email protected]/svnroot/rcpp
Repository UUID: edb9625f-4e0d-4859-8d74-9fd3b1da38cb
Revision: 4521
Node Kind: directory
Schedule: normal
Last Changed Author: romain
Last Changed Rev: 4521
Last Changed Date: 2013-09-19 10:16:41 -0500 (Thu, 19 Sep 2013)

edd@max:~/svn/rcpp/pkg$ R CMD check --no-vignettes Rcpp_0.10.4.5.tar.gz
* using log directory ‘/home/edd/svn/rcpp/pkg/Rcpp.Rcheck’
* using R version 3.0.1 (2013-05-16)
* using platform: x86_64-pc-linux-gnu (64-bit)
* using session charset: UTF-8
* using option ‘--no-vignettes’
* checking for file ‘Rcpp/DESCRIPTION’ ... OK
* this is package ‘Rcpp’ version ‘0.10.4.5’
* checking CRAN incoming feasibility ... OK
Maintainer: ‘Dirk Eddelbuettel <[email protected]>’
* checking package namespace information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking whether package ‘Rcpp’ can be installed ... WARNING
Found the following significant warnings:
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:205:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
   ../inst/include/Rcpp/platform/compiler.h:206:19: warning: ISO C++ 1998 does 
not support ‘long long’ [-Wlong-long]
See ‘/home/edd/svn/rcpp/pkg/Rcpp.Rcheck/00install.out’ for details.
* checking installed package size ... NOTE
   installed size is 24.7Mb
   sub-directories of 1Mb or more:
     doc       2.0Mb
     include   6.3Mb
     lib      11.6Mb
     libs      3.4Mb
* checking package directory ... OK
* checking DESCRIPTION meta-information ... OK
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking R files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking for unstated dependencies in R code ... OK
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... OK
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking for portable compilation flags in Makevars ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking compiled code ... OK
* checking sizes of PDF files under ‘inst/doc’ ... OK
* checking installed files from ‘inst/doc’ ... OK
* checking examples ... OK
* checking for unstated dependencies in tests ... OK
* checking tests ...
   Running ‘doRUnit.R’ [103s/91s]
  [104s/92s] OK
* checking for unstated dependencies in vignettes ... OK
* checking package vignettes in ‘inst/doc’ ... OK
* checking running R code from vignettes ... SKIPPED
* checking re-building of vignettes ... SKIPPED
* checking PDF version of manual ... OK

WARNING: There was 1 warning.
NOTE: There was 1 note.
See
   ‘/home/edd/svn/rcpp/pkg/Rcpp.Rcheck/00check.log’
for details.

edd@max:~/svn/rcpp/pkg$





--
Romain Francois
Professional R Enthusiast
+33(0) 6 28 91 30 30

_______________________________________________
Rcpp-devel mailing list
[email protected]
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel

Reply via email to