cplus_demangle 0.1.0

Rust wrapper for GNU libiberty's cplus_demangle to demangle C++ symbols
docs.rs failed to build cplus_demangle-0.1.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build: cplus_demangle-0.1.2

cplus_demangle

cplus_demangle

This library converts C++ mangled symbol names to human-readable strings. It is a small and safe Rust wrapper to GNU libiberty's C function cplus_demangle.

Example

Suppose you compile the following C++ program:

namespace test {
  void myfn(int x) { }
}

In the resulting binary, the symbol that gets generated for myfn is _ZN4test4myfnEi. We can convert it back with this Rust code:

assert_eq!(cplus_demangle::demangle("_ZN4test4myfnEi").unwrap(), "test::myfn(int)");