Web lists-archives.org

Re: [Mingw-users] [BUG] - member is template<T>: ice in 4.2.1-sjlj (mingw32-2), bad compilation in 3




Hi John,

On Thu, 2007-12-20 at 10:21 -0500, John Brown wrote:
> Why does gcc have to use such ugly typenames? Another exercise
> produces
> the following output: 

You can use c++filt (part of binutils) to demangle the names, but
there's a catch.  The output of the typeid(x).name() string does not
match the format that c++filt expects (not sure why, but more info here
http://gcc.gnu.org/ml/gcc-patches/2002-01/msg02107.html )

You can prefix the mangled type name with a _Z to get the proper
demangled type name.

ex:

for
> St6vectorISsSaISsEE

c++filt _ZSt6vectorISsSaISsEE yields

std::vector<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::allocator<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > > >

Notice the _Z prefix.

Hope this helps,
- Dave


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
MinGW-users mailing list
MinGW-users@xxxxxxxxxxxxxxxxxxxxx

You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users