diff options
Diffstat (limited to 'zenutil')
| -rw-r--r-- | zenutil/include/zenutil/cache/cachekey.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/zenutil/include/zenutil/cache/cachekey.h b/zenutil/include/zenutil/cache/cachekey.h index 569a31441..427c99435 100644 --- a/zenutil/include/zenutil/cache/cachekey.h +++ b/zenutil/include/zenutil/cache/cachekey.h @@ -23,13 +23,19 @@ struct CacheKey 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; + if (auto n = caseSensitiveCompareStrings(Namespace, that.Namespace); n != std::strong_ordering::equal) + { + return n; + } + if (auto b = caseSensitiveCompareStrings(Bucket, that.Bucket); b != std::strong_ordering::equal) + { + return b; + } return Hash <=> that.Hash; } + auto operator==(const CacheKey& that) const { return (*this <=> that) == std::strong_ordering::equal; } + static const CacheKey Empty; }; |