Skip to content

Commit

Permalink
Load cfloat to define DBL_MAX when strict R headers are set
Browse files Browse the repository at this point in the history
  • Loading branch information
TReynkens committed Sep 18, 2018
1 parent e6c85f6 commit aceb4d5
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 4 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: ReIns
Version: 1.0.7.9000
Date: 2018-09-03
Version: 1.0.8
Date: 2018-09-18
Title: Functions from "Reinsurance: Actuarial and Statistical Aspects"
Description: Functions from the book "Reinsurance: Actuarial and Statistical Aspects" (2017) by Hansjoerg Albrecher, Jan Beirlant and Jef Teugels <http://www.wiley.com/WileyCDA/WileyTitle/productCd-0470772689.html>.
Authors@R: c(
Expand Down
8 changes: 7 additions & 1 deletion inst/NEWS.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,14 @@
\title{News for package "ReIns"}
\encoding{UTF-8}

\section{Changes in version 1.0.8 (2018-04-24)}{
\section{Changes in version 1.0.8 (2018-09-18)}{

\subsection{Changes in \code{C++} code:}{
\itemize{
\item Load \code{cfloat} to define \code{DBL_MAX} when strict R headers are set (flag \code{-DSTRICT_R_HEADERS} in MAKEVARS) as this will be done by default in \pkg{Rcpp} in September 2019. See \url{https://github.com/RcppCore/Rcpp/issues/898} for more details. This fixes \url{https://github.com/TReynkens/ReIns/issues/2}.
}
}

\subsection{Miscellaneous changes:}{
\itemize{
\item Update URL for SOA data.
Expand Down
5 changes: 4 additions & 1 deletion src/Makevars
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
# Use C++11
CXX_STD = CXX11
CXX_STD = CXX11

# Set strict R headers, this will be enabled in Rcpp by default in September 2019
PKG_CXXFLAGS = -DSTRICT_R_HEADERS
1 change: 1 addition & 0 deletions src/SpliceEM_aux.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
// Include libraries and header files
#include <iostream> // Input and output
#include <cmath> // C numerics library
#include <cfloat> // Characteristics of floating-point types

// R functionality
#include <Rcpp.h> // R/C++ interface class library
Expand Down

0 comments on commit aceb4d5

Please sign in to comment.