#include <cxxabi.h>
#include <iostream>
std::string demangle_type(const std::string& mangled)
{
char *demangled = abi::__cxa_demangle(mangled.c_str(), 0, 0, 0);
std::string result {demangled};
free(demangled);
return result;
}
int main()
{
using namespace std;
cout << demangle_type("3barI5emptyLi17EE") << endl;
}
I2luY2x1ZGUgPGN4eGFiaS5oPgojaW5jbHVkZSA8aW9zdHJlYW0+CgpzdGQ6OnN0cmluZyBkZW1hbmdsZV90eXBlKGNvbnN0IHN0ZDo6c3RyaW5nJiBtYW5nbGVkKQp7CiAgICBjaGFyICpkZW1hbmdsZWQgPSBhYmk6Ol9fY3hhX2RlbWFuZ2xlKG1hbmdsZWQuY19zdHIoKSwgMCwgMCwgMCk7CiAgICBzdGQ6OnN0cmluZyByZXN1bHQge2RlbWFuZ2xlZH07CiAgICBmcmVlKGRlbWFuZ2xlZCk7CiAgICByZXR1cm4gcmVzdWx0Owp9CgppbnQgbWFpbigpCnsKICAgIHVzaW5nIG5hbWVzcGFjZSBzdGQ7CgogICAgY291dCA8PCBkZW1hbmdsZV90eXBlKCIzYmFySTVlbXB0eUxpMTdFRSIpIDw8IGVuZGw7Cn0=