From fbbc92c5d74f4724f32bb6cc23af4da93f75592e Mon Sep 17 00:00:00 2001 From: Thomas Krijnen Date: Wed, 14 Jan 2026 14:03:55 +0100 Subject: [PATCH] Hashing solely based on identity --- src/ifcwrap/IfcParseWrapper.i | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/ifcwrap/IfcParseWrapper.i b/src/ifcwrap/IfcParseWrapper.i index 2fbc43b079..fb5b1b479d 100644 --- a/src/ifcwrap/IfcParseWrapper.i +++ b/src/ifcwrap/IfcParseWrapper.i @@ -470,9 +470,13 @@ private: } size_t __hash__() const { - if (!self->declaration().as_entity()) { - return boost::hash>{}({self->identity(), self->file()}); - } else { + return boost::hash>{}({self->identity(), self->file()}); + // if (self->declaration().as_entity()) { + // } + } + + /* + else { return self->get_attribute_value(0).apply_visitor([&](const auto& val){ using U = std::decay_t; if constexpr (std::is_same_v || std::is_same_v || std::is_same_v || std::is_same_v || std::is_same_v || std::is_same_v) { @@ -484,6 +488,7 @@ private: }); } } + */ std::string __repr__() const { std::ostringstream oss;