From 6956c560330e21c7673ba8d5e43d53b71a7fce48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?B=C3=A5rd=20Sigurd=20M=C3=B8ller?= Date: Sat, 28 May 2022 20:55:51 +0200 Subject: [PATCH] Fix compilation error, when including magic_enum after windows.h (#189) --- include/magic_enum.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/magic_enum.hpp b/include/magic_enum.hpp index c6a48fb..886f888 100644 --- a/include/magic_enum.hpp +++ b/include/magic_enum.hpp @@ -739,7 +739,7 @@ struct constexpr_hash_t(2166136261ULL); for (const auto c : value) { - acc = ((acc ^ static_cast(c)) * static_cast(16777619ULL)) & std::numeric_limits::max(); + acc = ((acc ^ static_cast(c)) * static_cast(16777619ULL)) & (std::numeric_limits::max)(); } return static_cast(acc); }