aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--zenutil/include/zenutil/cache/cachekey.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/zenutil/include/zenutil/cache/cachekey.h b/zenutil/include/zenutil/cache/cachekey.h
index 9d0a4ba6d..569a31441 100644
--- a/zenutil/include/zenutil/cache/cachekey.h
+++ b/zenutil/include/zenutil/cache/cachekey.h
@@ -21,7 +21,14 @@ struct CacheKey
return {.Namespace = ToLower(Namespace), .Bucket = ToLower(Bucket), .Hash = Hash};
}
- auto operator<=>(const CacheKey&) const = default;
+ auto operator<=>(const CacheKey& that) const
+ {
+ if (auto cmp = Namespace <=> that.Namespace; cmp != 0)
+ return cmp;
+ if (auto cmp = Bucket <=> that.Bucket; cmp != 0)
+ return cmp;
+ return Hash <=> that.Hash;
+ }
static const CacheKey Empty;
};