//
// tinyxml2::XMLDocument::NewDeclaration from 0x5ee83c to 0x5ee86e (50 bytes)
//
// 2 xrefs:
// > cocos2d::CCFileUtils::writeToFile @ 0x5dec70
// > tinyxml2::XMLDeclaration::ShallowClone @ 0x5ee88a
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
tinyxml2::XMLNode *__fastcall tinyxml2::XMLDocument::NewDeclaration(tinyxml2::XMLDocument *this, const char *a2)
{
char *v2; // r6
tinyxml2::XMLDeclaration *v5; // r0
tinyxml2::XMLNode *v6; // r5
const char *v7; // r1
v2 = (char *)this + 296;
v5 = (tinyxml2::XMLDeclaration *)tinyxml2::MemPoolT<44>::Alloc((int)this + 296);
v6 = v5;
if ( v5 )
tinyxml2::XMLDeclaration::XMLDeclaration(v5, this);
*((_DWORD *)v6 + 10) = v2;
if ( a2 )
v7 = a2;
else
v7 = "xml version=\"1.0\" encoding=\"UTF-8\"";
tinyxml2::XMLNode::SetValue(v6, v7, 0);
return v6;
}