Compilation fixes

This commit is contained in:
Thomas Krijnen
2026-04-09 16:18:53 +02:00
parent 7d6c6bd523
commit becd38c77d
12 changed files with 24 additions and 24 deletions
+1 -1
View File
@@ -40,7 +40,7 @@
#define IfcSchema Ifc2x3
#include "../ifcparse/macros.h"
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/hierarchy_helper.h"
#include "../ifcgeom/Serialization/Serialization.h"
+1 -1
View File
@@ -37,7 +37,7 @@
#define IfcSchema Ifc2x3
#include "../ifcparse/macros.h"
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/hierarchy_helper.h"
#include "../ifcgeom/Serialization/Serialization.h"
+2 -2
View File
@@ -22,7 +22,7 @@
#include "../ifcparse/file.h"
#include "../ifcparse/logger.h"
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include <boost/preprocessor/stringize.hpp>
#include <boost/preprocessor/seq/for_each.hpp>
@@ -47,7 +47,7 @@ static_assert(false, "A boost preprocessor sequence of schema identifiers is nee
// for and then overflow into an existing empty include file.
#define INCLUDE_SCHEMA(n) \
BOOST_PP_IIF(BOOST_PP_GREATER(BOOST_PP_SEQ_SIZE(SCHEMA_SEQ), n), BOOST_PP_STRINGIZE(../ifcparse/BOOST_PP_CAT(Ifc,BOOST_PP_SEQ_ELEM(BOOST_PP_MIN(n, BOOST_PP_SEQ_SIZE(BOOST_PP_SEQ_POP_BACK(SCHEMA_SEQ))),SCHEMA_SEQ)).h), "../ifcgeom/empty.h")
BOOST_PP_IIF(BOOST_PP_GREATER(BOOST_PP_SEQ_SIZE(SCHEMA_SEQ), n), BOOST_PP_STRINGIZE(../ifcparse/schemas/BOOST_PP_CAT(Ifc,BOOST_PP_SEQ_ELEM(BOOST_PP_MIN(n, BOOST_PP_SEQ_SIZE(BOOST_PP_SEQ_POP_BACK(SCHEMA_SEQ))),SCHEMA_SEQ)).h), "../ifcgeom/empty.h")
#include INCLUDE_SCHEMA(0)
#include INCLUDE_SCHEMA(1)
+1 -1
View File
@@ -28,7 +28,7 @@
#include <iostream>
#include <fstream>
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
+1 -1
View File
@@ -27,7 +27,7 @@
#include <iostream>
#include <fstream>
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
+1 -1
View File
@@ -27,7 +27,7 @@
#include <iostream>
#include <fstream>
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
+1 -1
View File
@@ -27,7 +27,7 @@
#include <iostream>
#include <fstream>
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
+2 -2
View File
@@ -23,7 +23,7 @@
* *
********************************************************************************/
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
@@ -204,4 +204,4 @@ int main(int argc, char** argv) {
file.header().file_name().name(filename);
std::ofstream f(filename.c_str());
f << file;
}
}
+1 -1
View File
@@ -27,7 +27,7 @@
#include <iostream>
#include <fstream>
#include "../ifcparse/Ifc2x3.h"
#include "../ifcparse/schemas/Ifc2x3.h"
#include "../ifcparse/IfcUtil.h"
#include "../ifcparse/hierarchy_helper.h"
+10 -10
View File
@@ -1408,19 +1408,19 @@ void parse_header(
read_terminal(lexer, HEADER, true);
read_terminal(lexer, Header_section_schema::file_description::Class().name_uc(), false);
header.set_file_description(read_header_entity(header.file(), storage, lexer, references_to_resolve, Header_section_schema::file_description::Class()));
header.set_file_description(read_header_entity(header.owner_file(), storage, lexer, references_to_resolve, Header_section_schema::file_description::Class()));
if (!lexer.next().is_operator(';')) {
throw exception("Expected ;");
}
read_terminal(lexer, Header_section_schema::file_name::Class().name_uc(), false);
header.set_file_name(read_header_entity(header.file(), storage, lexer, references_to_resolve, Header_section_schema::file_name::Class()));
header.set_file_name(read_header_entity(header.owner_file(), storage, lexer, references_to_resolve, Header_section_schema::file_name::Class()));
if (!lexer.next().is_operator(';')) {
throw exception("Expected ;");
}
read_terminal(lexer, Header_section_schema::file_schema::Class().name_uc(), false);
header.set_file_schema(read_header_entity(header.file(), storage, lexer, references_to_resolve, Header_section_schema::file_schema::Class()));
header.set_file_schema(read_header_entity(header.owner_file(), storage, lexer, references_to_resolve, Header_section_schema::file_schema::Class()));
if (!lexer.next().is_operator(';')) {
throw exception("Expected ;");
}
@@ -1452,7 +1452,7 @@ spf_header& ifcopenshell::instance_streamer<Reader>::ensure_header() {
if (owner_ != nullptr) {
header_ = &owner_->header();
header_->file(owner_);
header_->owner_file(owner_);
} else {
owned_header_ = std::make_unique<spf_header>(owner_);
header_ = owned_header_.get();
@@ -1859,7 +1859,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
auto& storage = byid_[p.first.name_];
auto attr_index = p.first.index_;
if (storage->has_attribute_value<express::Base>(attr_index)) {
if (storage->template has_attribute_value<express::Base>(attr_index)) {
express::Base inst = storage->get_attribute_value(attr_index);
if (!inst.declaration().as_entity()) {
// Probably a case of IfcPropertySetDefinitionSet, divert storage of reference to the simply type instance
@@ -1868,7 +1868,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
}
}
if (storage->has_attribute_value<blank>(attr_index)) {
if (storage->template has_attribute_value<blank>(attr_index)) {
storage->set_attribute_value(attr_index, express::Base(it->second));
} else {
logger::error("Duplicate definition for instance reference");
@@ -1899,7 +1899,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
auto& storage = byid_[p.first.name_];
auto attr_index = p.first.index_;
if (storage->has_attribute_value<express::Base>(attr_index)) {
if (storage->template has_attribute_value<express::Base>(attr_index)) {
express::Base inst = storage->get_attribute_value(attr_index);
if (!inst.declaration().as_entity()) {
// Probably a case of IfcPropertySetDefinitionSet, divert storage of reference to the simply type instance
@@ -1908,7 +1908,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
}
}
if (storage->has_attribute_value<blank>(attr_index)) {
if (storage->template has_attribute_value<blank>(attr_index)) {
storage->set_attribute_value(attr_index, instances);
} else {
logger::error("Duplicate definition for instance reference");
@@ -1937,7 +1937,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
auto& storage = byid_[p.first.name_];
auto attr_index = p.first.index_;
if (storage->has_attribute_value<express::Base>(attr_index)) {
if (storage->template has_attribute_value<express::Base>(attr_index)) {
express::Base inst = storage->get_attribute_value(attr_index);
if (!inst.declaration().as_entity()) {
// Probably a case of IfcPropertySetDefinitionSet, divert storage of reference to the simply type instance
@@ -1946,7 +1946,7 @@ void ifcopenshell::impl::in_memory_file_storage::read_from_stream(Reader* s, con
}
}
if (storage->has_attribute_value<blank>(attr_index)) {
if (storage->template has_attribute_value<blank>(attr_index)) {
storage->set_attribute_value(attr_index, instances);
} else {
logger::error("Duplicate definition for instance reference");
+1 -1
View File
@@ -56,7 +56,7 @@ void spf_header::write(std::ostream& out) const {
<< "\n";
}
void ifcopenshell::spf_header::file(ifcopenshell::file* file) {
void ifcopenshell::spf_header::owner_file(ifcopenshell::file* file) {
file_ = file;
}
+2 -2
View File
@@ -40,8 +40,8 @@ class IFC_PARSE_API spf_header {
void write(std::ostream& stream) const;
ifcopenshell::file* file() { return file_; }
void file(ifcopenshell::file* owner_file);
ifcopenshell::file* owner_file() { return file_; }
void owner_file(ifcopenshell::file* file);
void set_file_description(const std::shared_ptr<instance_data>& description_data);
void set_file_name(const std::shared_ptr<instance_data>& name_data);