-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Description
Hi,
the following fails to compile with the recent fixes inside chrono (the milliseconds handling), which broke compilation of the chrono fuzzer.
TEST(ChronoTest, StdChronoCompiletimeOverflowCheckLarge) {
// this wont compile, fails on the internal overflow check
// in std::ratio for libstdc++ (gnu)
using Large = std::chrono::duration<float, std::exa>;
EXPECT_TRUE("" != fmt::format("{}", Large{1}));
}
TEST(ChronoTest, StdChronoCompiletimeOverflowCheckSmall) {
// this works fine
using Small = std::chrono::duration<float, std::atto>;
EXPECT_TRUE("" != fmt::format("{}", Small{1}));
}
I am not sure what is the best route forward - it would be nice if all the standard prefixes are supported (peta works, it is only exa that doesn't).
If anyone actually uses exaseconds as their unit, it would be very interesting to hear what problem and/or domain they work with :-)
Metadata
Metadata
Assignees
Labels
No labels