test: add a fallback definition for std::chrono::days
This commit is contained in:
parent
99b9fbf8ef
commit
25a9beedb0
@ -24,6 +24,12 @@ using testing::Contains;
|
|||||||
# define FMT_HAS_C99_STRFTIME 1
|
# define FMT_HAS_C99_STRFTIME 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(__cpp_lib_chrono) && __cpp_lib_chrono >= 201907L
|
||||||
|
using days = std::chrono::days;
|
||||||
|
#else
|
||||||
|
using days = std::chrono::duration<std::chrono::hours::rep, std::ratio<86400>>;
|
||||||
|
#endif
|
||||||
|
|
||||||
auto make_tm() -> std::tm {
|
auto make_tm() -> std::tm {
|
||||||
auto time = std::tm();
|
auto time = std::tm();
|
||||||
time.tm_mday = 1;
|
time.tm_mday = 1;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user