From 646ae570426925ee72b98306a58be9911f959894 Mon Sep 17 00:00:00 2001 From: Alisenai <13826789+alisenai@users.noreply.github.com> Date: Sun, 14 Nov 2021 03:52:27 -0800 Subject: [PATCH] Support for building with LLVM clang-10/clang-11 on Windows. (#1227) * Fix enum underlying type specification * Fix C++0x-only solution --- include/benchmark/benchmark.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/include/benchmark/benchmark.h b/include/benchmark/benchmark.h index 45f26c8e94..31f6173584 100644 --- a/include/benchmark/benchmark.h +++ b/include/benchmark/benchmark.h @@ -453,27 +453,27 @@ class Counter { kDefaults = 0, // Mark the counter as a rate. It will be presented divided // by the duration of the benchmark. - kIsRate = 1U << 0U, + kIsRate = 1 << 0, // Mark the counter as a thread-average quantity. It will be // presented divided by the number of threads. - kAvgThreads = 1U << 1U, + kAvgThreads = 1 << 1, // Mark the counter as a thread-average rate. See above. kAvgThreadsRate = kIsRate | kAvgThreads, // Mark the counter as a constant value, valid/same for *every* iteration. // When reporting, it will be *multiplied* by the iteration count. - kIsIterationInvariant = 1U << 2U, + kIsIterationInvariant = 1 << 2, // Mark the counter as a constant rate. // When reporting, it will be *multiplied* by the iteration count // and then divided by the duration of the benchmark. kIsIterationInvariantRate = kIsRate | kIsIterationInvariant, // Mark the counter as a iteration-average quantity. // It will be presented divided by the number of iterations. - kAvgIterations = 1U << 3U, + kAvgIterations = 1 << 3, // Mark the counter as a iteration-average rate. See above. kAvgIterationsRate = kIsRate | kAvgIterations, // In the end, invert the result. This is always done last! - kInvert = 1U << 31U + kInvert = 1 << 31 }; enum OneK {