From: wolf Date: Thu, 11 Aug 2005 18:43:49 +0000 (+0000) Subject: Print stacktraces gdb-style, i.e. with a prefixed frame number. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8599f0c1a91b101306697310704ef895c70642c2;p=dealii-svn.git Print stacktraces gdb-style, i.e. with a prefixed frame number. git-svn-id: https://svn.dealii.org/trunk@11291 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/base/source/exceptions.cc b/deal.II/base/source/exceptions.cc index 71bae91229..f70b54a549 100644 --- a/deal.II/base/source/exceptions.cc +++ b/deal.II/base/source/exceptions.cc @@ -157,9 +157,12 @@ void ExceptionBase::print_stack_trace (std::ostream &out) const ++frame; // output the rest + const unsigned int first_significant_frame = frame; for (; frame < n_stacktrace_frames; ++frame) - out << stacktrace[frame] - << std::endl; + out << '#' << frame - first_significant_frame + << " " + << stacktrace[frame] + << std::endl; }