From bb6a3421d27b19d8caa203cca96f47210a670070 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Mon, 9 Sep 2019 16:46:46 -0300 Subject: Fix declarations hashing --- src/sirit.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/sirit.cpp') diff --git a/src/sirit.cpp b/src/sirit.cpp index 50135e3..f65e9a5 100644 --- a/src/sirit.cpp +++ b/src/sirit.cpp @@ -20,6 +20,15 @@ static void WriteSet(Stream& stream, const T& set) { } } +std::size_t Module::HashOp::operator()(const std::unique_ptr& op) const noexcept { + return op->Hash(); +} + +bool Module::EqualOp::operator()(const std::unique_ptr& lhs, + const std::unique_ptr& rhs) const noexcept { + return *lhs == *rhs; +} + Module::Module(u32 version) : version(version) {} Module::~Module() = default; -- cgit v1.2.3