pub enum Context {
Linear,
RefCounting,
Async,
Comptime,
GPU,
SIMD,
Safe,
General,
}Expand description
意图上下文 (Intent Context) 约束的容器和作用范围。
Variants§
Linear
线性生命周期上下文 (Ownership, Move semantics)
RefCounting
引用计数上下文 (Swift ARC, Python RC)
Async
异步调度上下文 (Kotlin Coroutines, Go Goroutines)
Comptime
编译时上下文 (Zig comptime, Mojo static evaluation)
GPU
硬件相关:GPU 硬件加速上下文
SIMD
硬件相关:SIMD 向量化上下文
Safe
内存安全:非空约束 (Kotlin Non-null, Swift Optional)
General
默认通用上下文
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Context
impl<'de> Deserialize<'de> for Context
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Context
impl StructuralPartialEq for Context
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl UnsafeUnpin for Context
impl UnwindSafe for Context
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