|
int | __cxa_atexit (void(*)(void *), void *, void *) _GLIBCXX_NOTHROW |
|
void | __cxa_bad_cast () __attribute__((__noreturn__)) |
|
void | __cxa_bad_typeid () __attribute__((__noreturn__)) |
|
void | __cxa_deleted_virtual (void) __attribute__((__noreturn__)) |
|
char * | __cxa_demangle (const char *__mangled_name, char *__output_buffer, size_t *__length, int *__status) |
| Demangling routine. More...
|
|
int | __cxa_finalize (void *) |
|
void | __cxa_guard_abort (__guard *) _GLIBCXX_NOTHROW |
|
int | __cxa_guard_acquire (__guard *) |
|
void | __cxa_guard_release (__guard *) _GLIBCXX_NOTHROW |
|
void | __cxa_pure_virtual (void) __attribute__((__noreturn__)) |
|
int | __cxa_thread_atexit (void(*)(void *), void *, void *) _GLIBCXX_NOTHROW |
|
void | __cxa_throw_bad_array_new_length () __attribute__((__noreturn__)) |
|
__cxa_vec_ctor_return_type | __cxa_vec_cctor (void *__dest_array, void *__src_array, size_t __element_count, size_t __element_size, __cxa_cdtor_return_type(*__constructor)(void *, void *), __cxa_cdtor_type __destructor) |
|
void | __cxa_vec_cleanup (void *__array_address, size_t __element_count, size_t __s, __cxa_cdtor_type __destructor) _GLIBCXX_NOTHROW |
|
__cxa_vec_ctor_return_type | __cxa_vec_ctor (void *__array_address, size_t __element_count, size_t __element_size, __cxa_cdtor_type __constructor, __cxa_cdtor_type __destructor) |
|
void | __cxa_vec_delete (void *__array_address, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __destructor) |
|
void | __cxa_vec_delete2 (void *__array_address, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __destructor, void(*__dealloc)(void *)) |
|
void | __cxa_vec_delete3 (void *__array_address, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __destructor, void(*__dealloc)(void *, size_t)) |
|
void | __cxa_vec_dtor (void *__array_address, size_t __element_count, size_t __element_size, __cxa_cdtor_type __destructor) |
|
void * | __cxa_vec_new (size_t __element_count, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __constructor, __cxa_cdtor_type __destructor) |
|
void * | __cxa_vec_new2 (size_t __element_count, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __constructor, __cxa_cdtor_type __destructor, void *(*__alloc)(size_t), void(*__dealloc)(void *)) |
|
void * | __cxa_vec_new3 (size_t __element_count, size_t __element_size, size_t __padding_size, __cxa_cdtor_type __constructor, __cxa_cdtor_type __destructor, void *(*__alloc)(size_t), void(*__dealloc)(void *, size_t)) |
|
The header provides an interface to the C++ ABI.
char* __cxa_demangle |
( |
const char * |
__mangled_name, |
|
|
char * |
__output_buffer, |
|
|
size_t * |
__length, |
|
|
int * |
__status |
|
) |
| |
Demangling routine.
ABI-mandated entry point in the C++ runtime library for demangling.
- Parameters
-
__mangled_name | A NUL-terminated character string containing the name to be demangled. |
__output_buffer | A region of memory, allocated with malloc, of *__length bytes, into which the demangled name is stored. If __output_buffer is not long enough, it is expanded using realloc. __output_buffer may instead be NULL; in that case, the demangled name is placed in a region of memory allocated with malloc. |
__length | If __length is non-NULL, the length of the buffer containing the demangled name is placed in *__length. |
__status | *__status is set to one of the following values: 0: The demangling operation succeeded. -1: A memory allocation failure occurred. -2: mangled_name is not a valid name under the C++ ABI mangling rules. -3: One of the arguments is invalid. |
- Returns
- A pointer to the start of the NUL-terminated demangled name, or NULL if the demangling fails. The caller is responsible for deallocating this memory using
free
.
The demangling is performed using the C++ ABI mangling rules, with GNU extensions. For example, this function is used in __gnu_cxx::__verbose_terminate_handler.
See http://gcc.gnu.org/onlinedocs/libstdc++/manual/bk01pt12ch39.html for other examples of use.
- Note
- The same demangling functionality is available via libiberty (
<libiberty/demangle.h>
and libiberty.a
) in GCC 3.1 and later, but that requires explicit installation (–enable-install-libiberty
) and uses a different API, although the ABI is unchanged.