fix mac buildbot for real
MODIFY
ir/memory.cpp
ir/memory.cpp
@@ -1070,6 +1070,16 @@ void Memory::AliasSet::print(ostream &os) const {
os << "(empty)";
}
+weak_ordering Memory::MemBlock::operator<=>(const MemBlock &rhs) const {
+ // FIXME:
+ // 1) xcode doesn't have tuple::operator<=>
+ // 2) gcc has a bug and can't generate the default
+ if (auto cmp = val <=> rhs.val; is_neq(cmp)) return cmp;
+ if (auto cmp = undef <=> rhs.undef; is_neq(cmp)) return cmp;
+ if (auto cmp = type <=> rhs.type; is_neq(cmp)) return cmp;
+ return weak_ordering::equivalent;
+}
+
static set<Pointer> all_leaf_ptrs(const Memory &m, const expr &ptr) {
set<Pointer> ptrs;

MODIFY
ir/memory.h
ir/memory.h
#include "smt/expr.h"
#include "smt/exprs.h"
#include "util/spaceship.h"
+#include <compare>
#include <map>
#include <optional>
#include <ostream>
@@ -242,10 +243,7 @@ class Memory {
MemBlock(smt::expr &&val, DataType type)
: val(std::move(val)), type(type) {}
- auto operator<=>(const MemBlock &rhs) const {
- return std::tie(val, undef, type) <=>
- std::tie(rhs.val, rhs.undef, rhs.type);
- }
+ std::weak_ordering operator<=>(const MemBlock &rhs) const;
};
std::vector<MemBlock> non_local_block_val;

fix mac buildbot for real