void print_trace (std::ostream &out=std::cerr)
Definition at line 70 of file print_trace.C.
References abi_demangle().
{
void *addresses[10];
char **strings;
int size = backtrace(addresses, 10);
strings = backtrace_symbols(addresses, size);
out << 'Stack frames: ' << size << std::endl;
for(int i = 0; i < size; i++)
{
// out << i << ': ' << (int)addresses[i] << std::endl;
// out << abi_demangle(strings[i]) << std::endl;
out << i << ': ' << abi_demangle(strings[i]) << std::endl;
}
std::free(strings);
}
Generated automatically by Doxygen for libMesh from the source code.