From 4c62c610045f64805d89fe36ee873f2bf10ba33c Mon Sep 17 00:00:00 2001 From: Otto Moerbeek Date: Wed, 3 Apr 2024 14:25:15 +0200 Subject: [PATCH] A few type fixes, mostly cosmetical --- pdns/stat_t.hh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pdns/stat_t.hh b/pdns/stat_t.hh index b084e761ec..96c7433514 100644 --- a/pdns/stat_t.hh +++ b/pdns/stat_t.hh @@ -62,11 +62,11 @@ namespace pdns { base_t operator--() { return --(ref()); } - base_t operator+=(const stat_t_trait& arg) { - return ref() += arg.ref(); + base_t operator+=(base_t arg) { + return ref() += arg; } - base_t operator-=(const stat_t_trait& arg) { - return ref() -= arg.ref(); + base_t operator-=(base_t arg) { + return ref() -= arg; } base_t load() const { return ref().load(); @@ -85,7 +85,7 @@ namespace pdns { const atomic_t& ref() const { return *reinterpret_cast(&counter); // NOLINT(cppcoreguidelines-pro-type-reinterpret-cast) } - typename std::aligned_storage_t counter; + typename std::aligned_storage_t counter; }; using stat_t = stat_t_trait; -- 2.47.2