Skip to content

Tracking issue for std::thread::ThreadId #21507

@aldanor

Description

@aldanor

Update description

Tracking issue for std::thread::ThreadId. Points to consider when stabilizing:

  • Implementation of a mutex + u64, unconditional panic if space is exhausted
  • Various traits on ThreadId, including Copy

Original report

Not sure if it can be considered as bug but it sure cripples the existing threading API (e.g., makes it harder for a thread to identify itself or store/pass its identity).

// it could also be nice if Thread was able to return a unique integer id() (or hash itself?..).

Metadata

Metadata

Assignees

No one assigned

    Labels

    B-unstableBlocker: Implemented in the nightly compiler and unstable.T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.final-comment-periodIn the final comment period and will be merged soon unless new substantive objections are raised.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions