binaryninja.demangle.simplify_name_to_qualified_name

simplify_name_to_qualified_name(input_name, simplify=True)[source]

simplify_name_to_qualified_name simplifies a templated C++ name with default arguments and returns a qualified name. This can also tokenize a string to a qualified name with/without simplifying it

Parameters
  • input_name (Union[str, QualifiedName]) – String or qualified name to be simplified

  • simplify_name (bool) – (optional) Whether to simplify input string (no effect if given a qualified name; will always simplify)

Returns

simplified name (or one-element array containing the input if simplifier fails/cannot simplify)

Return type

QualifiedName

Example
>>> demangle.simplify_name_to_qualified_name(QualifiedName(["std", "__cxx11", "basic_string<wchar, std::char_traits<wchar>, std::allocator<wchar> >"]), True)
'std::wstring'
>>>