When compiling RcppCWB you may see the following warning:
/Library/Frameworks/R.framework/Versions/4.1/Resources/library/Rcpp/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
^
This does not result from C/C++ code of RcppCWB, but from the Rcpp package. Thus, compiling the Rcpp version currently available at CRAN (v1.0.6) also yields this warning. On my system:
../inst/include/Rcpp/DataFrame.h:136:18: warning: unused variable 'data' [-Wunused-variable]
SEXP data = Parent::get__();
This is just a warning and does not indicate real trouble. For the time being, the solution is to install an updated version of Rcpp not yet available at CRAN. A conversation on Stackoverflow explains that it is available via a drat repository:
install.packages("Rcpp", repos="https://rcppcore.github.io/drat")
The alterntive to updating Rcpp is to add the flag -Wno-unusedto the CXXFLAGS in ~/.R/Makevars, but this conceals something that can and should be fixed easily. This is why I think that using the updates of Rcpp is the better solution. In my case v1.0.6.7 did the job.
It is just a matter of time that a new Rcpp version is released via CRAN which will not result in the warning. Then this issue can be closed.
When compiling RcppCWB you may see the following warning:
This does not result from C/C++ code of RcppCWB, but from the Rcpp package. Thus, compiling the Rcpp version currently available at CRAN (v1.0.6) also yields this warning. On my system:
This is just a warning and does not indicate real trouble. For the time being, the solution is to install an updated version of Rcpp not yet available at CRAN. A conversation on Stackoverflow explains that it is available via a drat repository:
The alterntive to updating Rcpp is to add the flag
-Wno-unusedto the CXXFLAGS in~/.R/Makevars, but this conceals something that can and should be fixed easily. This is why I think that using the updates of Rcpp is the better solution. In my case v1.0.6.7 did the job.It is just a matter of time that a new Rcpp version is released via CRAN which will not result in the warning. Then this issue can be closed.