Is there an online name demangler for C++?

C++Demangler

C++ Problem Overview


I'm getting a fairly long and confusing link error, and would love it if I could just paste it into some textbox on some website and have the names un-mangled for me.

Does anyone know of such a service?

C++ Solutions


Solution 1 - C++

I have created such an online serivice: https://demangler.com">https://demangler.com</a>

This is a gcc c++ symbol demangler. You just copy a stack trace, or the output of nm into a text box, and it will return the output with the names demangled.

@Update: It now demangles MSVC and Java symbols also.

Solution 2 - C++

This might be a bit late, but I created one, based on this question. It works with the inputs I tried on, supports g++ and msvc++ via __cxa_demangle and __unDName, compiled to Javascript via Emscripten. Hope this helps someone: [c++filtjs][1]

Edit: Fixed escaping problem

[1]: http://d.fuqu.jp/c++filtjs/ "c++filtjs"

Solution 3 - C++

Most (if not all) C++ compilers come with c++filt tool which does precisely what you apparently looking for.

If you want it at the mouse click... well write a GUI for it ;)

Solution 4 - C++

There are two copy-and-paste online solutions:

If you only need support for GCC and Clang, you also have the option of using Coliru, which is probably the most versatile online C++ compiler.

This is not quite as simple as cut, paste, and click - but not too much harder - and it looks like there are no issues with template parameters as was noted above. You just need to modify the command line to run something like this:

cat main.cpp | c++filt -t

See it live with this example which demangles:

_Z6kernelIfLj3EEvPT_5arrayIPKS0_XT0_EES5_S2_IjXT0_EES6_S0_

to:

void kernel<float, 3u>(float*, array<float const*, 3u>, array<float const*, 3u>, array<unsigned int, 3u>, array<unsigned int, 3u>, float)
           ^^^^^^^^^^^

Solution 5 - C++

FYI, there's also a Ruby gem to demangle Borland/MS/whatever mangled names: unmangler

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionRoman StarkovView Question on Stackoverflow
Solution 1 - C++Rafael BaptistaView Answer on Stackoverflow
Solution 2 - C++nattofriendsView Answer on Stackoverflow
Solution 3 - C++Dummy00001View Answer on Stackoverflow
Solution 4 - C++Shafik YaghmourView Answer on Stackoverflow
Solution 5 - C++zed_0xffView Answer on Stackoverflow