-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#[track_caller] for allocator APIs? #74763
Comments
I'm not sure if this will work, given the indirection in Lines 77 to 81 in 8cb94fc
#[global_alloc] , per this comment.
|
Yeah, the only way to carry |
cc #74433 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Apologies if this has been raised before, but I've been playing around with trying to track where allocations happen with something like so:
However the caller location is always the line I've put
#[global_allocator]
which makes#[track_caller]
useless in this context.Originally posted by @xd009642 in #47809 (comment)
note from @anp: I'm not sure how the global allocator hooks in but this might be possible?
The text was updated successfully, but these errors were encountered: