Make operator<=> static
Apparently this counts as "namespace scope" (as opposed to an anonymous namespace), and it still won't be visible outside the translation unit.
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
|
||||
using Key = ConflictSet::Key;
|
||||
|
||||
auto operator<=>(const Key &lhs, const Key &rhs) {
|
||||
static auto operator<=>(const Key &lhs, const Key &rhs) {
|
||||
const int minLen = std::min(lhs.len, rhs.len);
|
||||
const int c = memcmp(lhs.p, rhs.p, minLen);
|
||||
return c != 0 ? c <=> 0 : lhs.len <=> rhs.len;
|
||||
|
Reference in New Issue
Block a user