From affb2a88419563c84d65b820c01466bca4594916 Mon Sep 17 00:00:00 2001 From: Dirk Vanden Boer Date: Tue, 16 Apr 2024 10:21:17 +0200 Subject: [PATCH] Improve chrono::year hash condition --- include/infra/chrono.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/include/infra/chrono.h b/include/infra/chrono.h index c303d001..07b952bd 100644 --- a/include/infra/chrono.h +++ b/include/infra/chrono.h @@ -249,15 +249,14 @@ class ScopedDurationLog } -#ifndef HAVE_CPP20_CHRONO - +#if __cplusplus < 202600L #include namespace std { template <> -struct hash +struct hash { - size_t operator()(const date::year& x) const + size_t operator()(const inf::chrono::year& x) const { return static_cast(x); }