forked from red-rocket-computing/backtrace
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for collecting frame information via callbacks.
In addition to the previous API where the caller provided a buffer and a size, it's now possible to instead proviced a callback and a context. This allows the caller to use their own data structures without having to allocate an additional set of objects to pass to backtrace. The old API is still intact but has internally been rewritten to also use the callback mechanisms. Note that this does increase the stack strain a bit as each frame has to go through the callback. Additionally, this also adds support for traversing a frame provided by the user, with or without callbacks). Closes red-rocket-computing#10
- Loading branch information
1 parent
a438f64
commit b112095
Showing
3 changed files
with
118 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters