From 40b821811176d69f15942fc1a35bbd00cf6940a1 Mon Sep 17 00:00:00 2001 From: Erik Schnetter Date: Mon, 22 Oct 2012 14:25:10 -0400 Subject: Remove Carpet's mechanisms to deal with how to call isnan Remove Carpet's mechanisms to deal with how to call isnan. Instead, expect isnan in std::, and rely on Cactus to correct things if this is not the case. --- Carpet/CarpetReduce/src/reduce.cc | 47 --------------------------------------- 1 file changed, 47 deletions(-) (limited to 'Carpet/CarpetReduce') diff --git a/Carpet/CarpetReduce/src/reduce.cc b/Carpet/CarpetReduce/src/reduce.cc index f9969647b..5ee5a6360 100644 --- a/Carpet/CarpetReduce/src/reduce.cc +++ b/Carpet/CarpetReduce/src/reduce.cc @@ -42,13 +42,6 @@ namespace CarpetReduce { // Helper functions and types - // Whether a value is nan - template static inline int - myisnan (const T x) - { - return isnan(x); - } - // The minimum of two values template static inline T mymin (const T x, const T y) @@ -127,11 +120,6 @@ namespace CarpetReduce { // The C++ compiler should supply these, but some old ones do not, // e.g. our beloved workhorse Intel 7.1. Self is the man. #ifdef HAVE_CCTK_BYTE -// template<> static inline int myisnan (CCTK_BYTE const x) -// { -// return 0; -// } - template<> inline CCTK_BYTE mysqr (CCTK_BYTE const x) { // prevent overflow @@ -152,11 +140,6 @@ namespace CarpetReduce { #endif #ifdef HAVE_CCTK_INT1 -// template<> static inline int myisnan (CCTK_INT1 const x) -// { -// return 0; -// } - template<> inline CCTK_INT1 mysqr (CCTK_INT1 const x) { // prevent overflow @@ -177,11 +160,6 @@ namespace CarpetReduce { #endif #ifdef HAVE_CCTK_INT2 -// template<> static inline int myisnan (CCTK_INT2 const x) -// { -// return 0; -// } - template<> inline CCTK_INT2 mysqr (CCTK_INT2 const x) { // prevent overflow @@ -202,11 +180,6 @@ namespace CarpetReduce { #endif #ifdef HAVE_CCTK_INT4 -// template<> inline int myisnan (CCTK_INT4 const x) -// { -// return 0; -// } - template<> inline CCTK_INT4 mysqr (CCTK_INT4 const x) { // prevent overflow @@ -227,11 +200,6 @@ namespace CarpetReduce { #endif #ifdef HAVE_CCTK_INT8 -// template<> inline int myisnan (CCTK_INT8 const x) -// { -// return 0; -// } - template<> inline CCTK_INT8 mysqr (CCTK_INT8 const x) { // prevent overflow @@ -257,11 +225,6 @@ namespace CarpetReduce { #ifdef HAVE_CCTK_REAL4 - // template<> inline int myisnan (complex const x) - // { - // return isnan (x.real()) or isnan (x.imag()); - // } - template<> inline complex mymin (const complex x, const complex y) { @@ -306,11 +269,6 @@ namespace CarpetReduce { #ifdef HAVE_CCTK_REAL8 - // template<> inline int myisnan (complex const x) - // { - // return isnan (x.real()) or isnan (x.imag()); - // } - template<> inline complex mymin (const complex x, const complex y) { @@ -355,11 +313,6 @@ namespace CarpetReduce { #ifdef HAVE_CCTK_REAL16 - // template<> inline int myisnan (complex const x) - // { - // return isnan (x.real()) or isnan (x.imag()); - // } - template<> inline complex mymin (const complex x, const complex y) { -- cgit v1.2.3