Skip to content

Support #[track_caller] on async fns#104219

Merged
bors merged 6 commits intorust-lang:masterfrom
bryangarza:async-track-caller-dup
Nov 17, 2022
Merged

Support #[track_caller] on async fns#104219
bors merged 6 commits intorust-lang:masterfrom
bryangarza:async-track-caller-dup

Conversation

@bryangarza
Copy link
Contributor

@bryangarza bryangarza commented Nov 9, 2022

Adds #[track_caller] to the generator that is created when we desugar the async fn.

Fixes #78840

Open questions:

  • What is the performance impact of adding #[track_caller] to every GenFuture's poll(...) function, even if it's unused (i.e., the parent span does not set #[track_caller])? We might need to set it only conditionally, if the indirection causes overhead we don't want.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

#[track_caller] does nothing on async fns

10 participants