math: correct the MSVCRT condition
Fixes a number of tests in the testsuite on Windows.
llvm-svn: 295330
Cr-Mirrored-From: sso://chromium.googlesource.com/_direct/external/github.com/llvm/llvm-project
Cr-Mirrored-Commit: 3d99648f00b0c96a6620b29e3648e5482344c188
diff --git a/include/math.h b/include/math.h
index 18dd3cc..54fd6f7 100644
--- a/include/math.h
+++ b/include/math.h
@@ -1020,7 +1020,7 @@
return ::copysign((__result_type)__lcpp_x, (__result_type)__lcpp_y);
}
-#if !defined(_LIBCPP_MSVCRT) || ((_VC_CRT_MAJOR_VERSION-0) >= 14)
+#if !(defined(_LIBCPP_MSVCRT) && ((_VC_CRT_NAJOR_VERSION-0) < 14))
// erf
@@ -1404,7 +1404,7 @@
typename std::enable_if<std::is_integral<_A1>::value, double>::type
trunc(_A1 __lcpp_x) _NOEXCEPT {return ::trunc((double)__lcpp_x);}
-#endif // !defined(_LIBCPP_MSVCRT) || ((_VC_CRT_MAJOR_VERSION-0) >= 14)
+#endif // !(defined(_LIBCPP_MSVCRT) && ((_VC_CRT_NAJOR_VERSION-0) < 14))
} // extern "C++"