From f6531b10353dacdcbab211a31926c165211cf3b3 Mon Sep 17 00:00:00 2001 From: Andreas Stöckel Date: Sat, 7 Feb 2015 02:31:51 +0100 Subject: Unified handling of references to Rtti instances: Now using pointers everywhere --- src/plugins/xml/XmlParser.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/plugins/xml/XmlParser.cpp') diff --git a/src/plugins/xml/XmlParser.cpp b/src/plugins/xml/XmlParser.cpp index bd9b681..4f956d5 100644 --- a/src/plugins/xml/XmlParser.cpp +++ b/src/plugins/xml/XmlParser.cpp @@ -97,7 +97,7 @@ public: { // check if the parent in the structure tree was an explicit field // reference. - inField = parentNode->isa(RttiTypes::DocumentField); + inField = parentNode->isa(&RttiTypes::DocumentField); if (inField) { fieldName = parentNode->getName(); parentNode = scope().selectOrThrow( @@ -108,10 +108,10 @@ public: } // reference the parent entity explicitly. parent = nullptr; - if (parentNode->isa(RttiTypes::StructuredEntity)) { + if (parentNode->isa(&RttiTypes::StructuredEntity)) { parent = static_cast( parentNode.cast().get()); - } else if (parentNode->isa(RttiTypes::AnnotationEntity)) { + } else if (parentNode->isa(&RttiTypes::AnnotationEntity)) { parent = static_cast( parentNode.cast().get()); } @@ -157,7 +157,7 @@ public: args.erase(it); } Rooted entity; - if (parentNode->isa(RttiTypes::Document)) { + if (parentNode->isa(&RttiTypes::Document)) { entity = parentNode.cast()->createRootStructuredEntity( strct, args, name); } else { @@ -762,7 +762,7 @@ public: Logger &logger) { if (parent != nullptr) { auto res = parent.cast()->resolve( - RttiTypes::FieldDescriptor, name); + &RttiTypes::FieldDescriptor, name); if (res.size() != 1) { logger.error( std::string("Could not find referenced field ") + name, @@ -840,7 +840,7 @@ public: // Fetch the last node and check whether an import is valid at this // position Rooted leaf = scope().getLeaf(); - if (leaf == nullptr || !leaf->isa(RttiTypes::RootNode)) { + if (leaf == nullptr || !leaf->isa(&RttiTypes::RootNode)) { logger().error( "Import not supported here, must be inside a document, domain " "or typesystem command.", -- cgit v1.2.3