Re: Where is docs for typeid(x).name()?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ian Lance Taylor skrev:
"Lee Rhodes" <lee@xxxxxxxxx> writes:

I have figured out by experimenting that typeid(x).name() produces:
'c' if x is type char
'h' if x is type unsigned char
'i' if x is type int
'j' if x is type unsigned int
...and so on.

Where can I find the full list of such symbolic representations of internal
types?

I believe they are mangled type names.  The mangling is described
in section 5.1.5 here:
    http://www.codesourcery.com/cxx-abi/abi.html#mangling

Ian



You can also use c++filt (included in binutils) to demangle names. Take a look at the source if you want to implement something similar into your application.

// David Sveningsson

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux