MCPcopy Create free account
hub / github.com/WheretIB/nullc / xml_document__root

Function xml_document__root

NULLC/includes/pugi.cpp:671–683  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

669 }
670
671 xml_node xml_document__root(xml_document* document)
672 {
673 if(!document->impl){ nullcThrowError("xml_document constructor wasn't called"); return xml_node(); }
674 pugi::xml_document *doc = document->impl->document;
675 if(!doc)
676 {
677 doc = document->impl->document = (pugi::xml_document*)nullcAllocate(sizeof(pugi::xml_document));
678 ::new(doc) pugi::xml_document();
679 }
680 xml_node ret;
681 ret.node = doc->root();
682 return ret;
683 }
684
685 void xml_document__finalize(xml_document_impl* document)
686 {

Callers

nothing calls this directly

Calls 4

nullcAllocateFunction · 0.85
rootMethod · 0.80
xml_nodeClass · 0.70
nullcThrowErrorFunction · 0.50

Tested by

no test coverage detected