Skip to content

Commit 8034a70

Browse files
authored
Check for libc++ instead of clang to workaround a libc++ bug. (danmar#3194)
1 parent de2e836 commit 8034a70

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/mathlib.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ double MathLib::toDoubleNumber(const std::string &str)
603603
// nullcheck
604604
if (isNullValue(str))
605605
return 0.0;
606-
#ifdef __clang__
606+
#ifdef _LIBCPP_VERSION
607607
if (isFloat(str)) // Workaround libc++ bug at http://llvm.org/bugs/show_bug.cgi?id=17782
608608
// TODO : handle locale
609609
return std::strtod(str.c_str(), nullptr);

0 commit comments

Comments
 (0)