#2486 store provenance to file also in simple type instances

This commit is contained in:
Thomas Krijnen
2022-10-08 15:16:53 +02:00
parent 4110b81270
commit 94ba1a121d
+5
View File
@@ -2056,6 +2056,11 @@ IfcUtil::IfcBaseClass* IfcFile::addEntity(IfcUtil::IfcBaseClass* entity, int id)
// The mapping by entity instance name is updated.
byid[new_id] = new_entity;
} else if (!new_entity->data().file) {
// For non-entity instances, no mappings are updated, but the file
// pointer has to be set, so that actual copies are created in subsequent
// times.
new_entity->data().file = this;
}
if (parsing_complete_ && ty->as_entity()) {