pub struct AsyncPromise {
pub id: PromiseId,
}Expand description
An async promise: a thin handle to a promise in the unified runtime’s
PromiseRegistry, which is the single source of truth for its state and its
settled value. The handle carries only the checked PromiseId (Copy,
runtime-scoped), so it holds no GC edges — the resolved value lives in the
registry (retained there via Rc), not on this handle.
Fields§
§id: PromiseIdTrait Implementations§
Source§impl Clone for AsyncPromise
impl Clone for AsyncPromise
Source§fn clone(&self) -> AsyncPromise
fn clone(&self) -> AsyncPromise
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for AsyncPromise
Auto Trait Implementations§
impl Freeze for AsyncPromise
impl RefUnwindSafe for AsyncPromise
impl Send for AsyncPromise
impl Sync for AsyncPromise
impl Unpin for AsyncPromise
impl UnsafeUnpin for AsyncPromise
impl UnwindSafe for AsyncPromise
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more