You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
formatC++20 std::format or std::print, and anything related to theminvalidResolved as invalid, i.e. not a buglibc++libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.
using Representation = double;
usingDuration = std::chrono::duration<Representation>;
using Clock = std::chrono::system_clock;
using TimePoint = std::chrono::time_point<Clock, Duration>;
TimePoint tp = {};
std::string time_string = std::format("{:%d.%m.%Y %H:%M:%S}", tp);
This results in the compile error:
error: invalid operands to binary expression ('basic_ostringstream<char>' and 'const std::chrono::time_point<std::chrono::system_clock, std::chrono::duration<double>>')
__os << __t;
~~~~ ^ ~~~
If you change the type def Representation to an integer or unsigned integer type, the code compiles.
System Info:
OS: Ubuntu 22.04 LTS
Clang-Version: 15.0.7
Here is a link with the code that produces the error at Compiler Explorer. The error is still present in the newest available Clang version (17.0.1) at Compiler explorer.
The text was updated successfully, but these errors were encountered:
formatC++20 std::format or std::print, and anything related to theminvalidResolved as invalid, i.e. not a buglibc++libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.
Consider the following code snippet:
This results in the compile error:
If you change the type def
Representation
to an integer or unsigned integer type, the code compiles.System Info:
Here is a link with the code that produces the error at Compiler Explorer. The error is still present in the newest available Clang version (17.0.1) at Compiler explorer.
The text was updated successfully, but these errors were encountered: