-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
Tracking Issue for generic Atomic #130539
Copy link
Copy link
Open
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for Tracking Issue.
Feature gate:
#![feature(generic_atomic)]This is a tracking issue for replacing the distinct
Atomic*types with a genericAtomic<T>type. This allows usingAtomicwith FFI type aliases and helps clean up some API surface. Only types with existingAtomicTare usable inAtomic<T>.Public API
Steps / History
Atomic<T>libs-team#443Atomic<T>as an alias toAtomicT: CreateAtomic<T>type alias (rebase) #136316AtomicTis an alias toAtomic<T>: core: make atomic primitives type aliases ofAtomic<T>#153015AtomicTtoAtomic<_>new/into_inner/from_ptr/as_ptr/Default/From<T>: core: make some fundamental atomic functions generic #153407AtomicU128/AtomicI128) #99069Unresolved Questions
Atomic<T>is soft-blocked on 128-bit atomics, because since trait implementations cannot be unstable, gatingAtomic<i128>separately fromAtomic<i32>isn't possible.AtomicI128could instead nameAtomic<Wrapper<i128>>for some unstable nameWrapperuntil 128-bit atomics are stable, to preventAtomic<i128>from being usable from stable earlier than intended.Footnotes
https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html ↩