18using llvm::itanium_demangle::starts_with;
42 const size_t Pos = S.find_first_not_of(
'_');
43 return Pos > 0 && Pos <= 4 && S[Pos] ==
'Z';
51 std::string &Result,
bool CanHaveLeadingDot,
53 char *Demangled =
nullptr;
56 if (CanHaveLeadingDot && MangledName.size() > 0 && MangledName[0] ==
'.') {
57 MangledName.remove_prefix(1);
static bool isRustEncoding(std::string_view S)
static bool isDLangEncoding(std::string_view S)
static bool isItaniumEncoding(std::string_view S)
bool nonMicrosoftDemangle(std::string_view MangledName, std::string &Result, bool CanHaveLeadingDot=true, bool ParseParams=true)
char * itaniumDemangle(std::string_view mangled_name, bool ParseParams=true)
Returns a non-NULL pointer to a NUL-terminated C style string that should be explicitly freed,...
char * dlangDemangle(std::string_view MangledName)
char * rustDemangle(std::string_view MangledName)
char * microsoftDemangle(std::string_view mangled_name, size_t *n_read, int *status, MSDemangleFlags Flags=MSDF_None)
Demangles the Microsoft symbol pointed at by mangled_name and returns it.
std::string demangle(std::string_view MangledName)
Attempt to demangle a string using different demangling schemes.