Tracking Issue for `context_ext`
Open
Nobody has claimed this yet.
A-async-await
AsyncAwait-Triaged
C-tracking-issue
F-context_ext
T-libs
WG-async
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
Feature gate: #![feature(context_ext)]
This is a tracking issue for allowing std::task::Context to carry arbitrary extension data.
Public API
impl Context {
fn ext(&mut self) -> &mut dyn Any;
}
impl ContextBuilder {
fn ext(self, data: &'a mut dyn Any) -> Self;
fn from(cx: &'a mut Context<'_>) -> Self;
fn waker(self, waker: &'a Waker) -> Self;
}
Steps / History
- Implementation: #123203
- Final comment period (FCP)^1
- Stabilization PR
Unresolved Questions
- passing refs maybe unsound
- too complex
- This causes Context to no longer be UnwindSafe, which may be a breaking change: https://github.com/rust-lang/rust/issues/125193 (the issue is closed but there still is a FIXME in the code)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Read the public API and implementation PR #123203 first, then review the unresolved questions, including the linked soundness and complexity discussions and issue #125193. The tracking work is done when the final comment period completes and a stabilization PR is opened or the remaining blockers are resolved.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend-api-design
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100