From 86b89f2153ae5730561a8790775b4c6a2935c73a Mon Sep 17 00:00:00 2001 From: Thomas Krijnen Date: Mon, 20 Oct 2025 10:37:35 +0200 Subject: [PATCH] Comment behaviour #7264 --- src/ifcparse/IfcFile.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ifcparse/IfcFile.cpp b/src/ifcparse/IfcFile.cpp index 2a00f313b2..d70222ebf0 100644 --- a/src/ifcparse/IfcFile.cpp +++ b/src/ifcparse/IfcFile.cpp @@ -748,6 +748,7 @@ std::optionalas_entity() || decl->as_type_declaration()) { auto* inst = file->schema()->instantiate(decl, rocks_db_attribute_storage{}); + // @todo maybe this needs to be set to file? In order to have a context (ie. rocksdb::db*) to write to? inst->file_ = nullptr; return file->addEntity(inst); } else { @@ -764,6 +765,7 @@ IfcUtil::IfcBaseClass* IfcParse::impl::in_memory_file_storage::create(const IfcP } else { throw std::runtime_error("Requires and entity or type declaration"); } + // file_ should be nullptr in order not to bypass addEntity() behaviour of registration in maps inst->file_ = nullptr; return file->addEntity(inst); }