From 1af948a7d4803199e7361a9447f45a632665656d Mon Sep 17 00:00:00 2001 From: msuih Date: Sun, 10 Nov 2019 07:48:42 +0200 Subject: [PATCH] Fix bitfield warning --- Utilities/BitField.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Utilities/BitField.h b/Utilities/BitField.h index c2903a0c5d..ba123dee8c 100644 --- a/Utilities/BitField.h +++ b/Utilities/BitField.h @@ -16,7 +16,7 @@ struct bf_base static constexpr uint bitsize = N; // All ones mask - static constexpr utype mask1 = static_cast(UINTMAX_MAX); + static constexpr utype mask1 = static_cast(~static_cast(0)); // Value mask static constexpr utype vmask = mask1 >> (bitmax - bitsize);