Bug description
Expected behavior
We can use most C++17 (and C++20) features.
But very common C++17 feature: std::from_chars for double not available
Actual behavior
We're using apple libc++, it's outdated.
https://github.com/facebookincubator/velox/actions/runs/18444778495/job/52549931371?pr=15134
In file included from /Users/runner/work/velox/velox/velox/functions/prestosql/registration/DateTimeFunctionsRegistration.cpp:18:
/Users/runner/work/velox/velox/./velox/functions/prestosql/DateTimeFunctions.h:1811:23: error: call to deleted function 'from_chars'
1811 | auto [_, error] = std::from_chars(
| ^~~~~~~~~~~~~~~
/Applications/Xcode_16.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__charconv/from_chars_integral.h:38:19: note: candidate function has been explicitly deleted
38 | from_chars_result from_chars(const char*, const char*, bool, int = 10) = delete;
| ^
/Applications/Xcode_16.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__charconv/from_chars_integral.h:224:1: note: candidate template ignored: requirement 'is_integral<double>::value' was not satisfied [with _Tp = double]
224 | from_chars(const char* __first, const char* __last, _Tp& __value) {
| ^
/Applications/Xcode_16.4.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/c++/v1/__charconv/from_chars_integral.h:230:1: note: candidate function template not viable: requires 4 arguments, but 3 were provided
230 | from_chars(const char* __first, const char* __last, _Tp& __value, int __base) {
| ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
How to fix this?
Ideally use llvm clang and llvm libc++21
It's available for macos15: https://formulae.brew.sh/formula/llvm
Alternatively we can use gnu libstdc++ which is also available on macos
System information
CI
Relevant logs
Bug description
Expected behavior
We can use most C++17 (and C++20) features.
But very common C++17 feature:
std::from_charsfordoublenot availableActual behavior
We're using apple libc++, it's outdated.
https://github.com/facebookincubator/velox/actions/runs/18444778495/job/52549931371?pr=15134
How to fix this?
Ideally use llvm clang and llvm libc++21
It's available for macos15: https://formulae.brew.sh/formula/llvm
Alternatively we can use gnu libstdc++ which is also available on macos
System information
CI
Relevant logs