From 21909f5affa108c6d565d3e1222a2e2039cb70fd Mon Sep 17 00:00:00 2001 From: peter Date: Fri, 7 Aug 2020 08:30:36 -0700 Subject: [PATCH] omit math.h under cpp --- c/tskit/core.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/c/tskit/core.h b/c/tskit/core.h index bf586ba2b6..3ffd2c87c9 100644 --- a/c/tskit/core.h +++ b/c/tskit/core.h @@ -39,8 +39,9 @@ extern "C" { #include #include -#ifdef __clang__ +#if defined(__clang__) && !defined(__cplusplus) /* Work around bug in clang >= 6.0, https://github.com/tskit-dev/tskit/issues/721 + * (note: fixed in clang January 2019) */ #if __has_builtin(__builtin_isnan) #undef isnan