Open aytey opened 3 years ago
You could print yourself in the order you want. The included printer is not fancy. You could copy paste it and modify it in your application.
The Printer is an object for the purpose of holding configuration options. A PR that adds a reverse option to the printer would be welcome.
Apologies if I missed this (I did search for "reverse", but searching for "backwards" clearly isn't going to work!), but is there a way to get
backwards-cpp
to spit out the stacktrace in reverse?I am currently using this code (from the README):
but I'd like to see the innermost frames at the top (like how you'd see it with
gdb
).I poked into
Printer::print
and this callsPrinter::print_stacktrace
, which then iterates (forward) on the content of the stacktrace, but it seems there's no way to ask it go to in reverse.So, two questions:
backwards-cpp
to give a reversed stacktrace?reversed=True
default argument toPrinter::print
/Printer::print_stacktrace
be acceptable as a PR?