Lines Matching refs:VMState
145 pub unsafe trait VMState { interface
168 pub const fn vmstate_scalar_type<T: VMState>(_: PhantomData<T>) -> VMStateFieldType { in vmstate_scalar_type()
174 pub const fn vmstate_base<T: VMState>(_: PhantomData<T>) -> VMStateField { in vmstate_base()
181 pub const fn vmstate_varray_flag<T: VMState>(_: PhantomData<T>) -> VMStateFlags { in vmstate_varray_flag()
317 unsafe impl $crate::vmstate::VMState for $tuple {
329 ($type:ty where $base:tt: VMState $($where:tt)*) => {
330 unsafe impl<$base> VMState for $type where $base: VMState $($where)* { impl
331 const SCALAR_TYPE: VMStateFieldType = <$base as VMState>::SCALAR_TYPE;
334 ..<$base as VMState>::BASE
336 const VARRAY_FLAG: VMStateFlags = <$base as VMState>::VARRAY_FLAG;
341 impl_vmstate_transparent!(std::cell::Cell<T> where T: VMState);
342 impl_vmstate_transparent!(std::cell::UnsafeCell<T> where T: VMState);
343 impl_vmstate_transparent!(std::pin::Pin<T> where T: VMState);
344 impl_vmstate_transparent!(crate::cell::BqlCell<T> where T: VMState);
345 impl_vmstate_transparent!(crate::cell::BqlRefCell<T> where T: VMState);
346 impl_vmstate_transparent!(crate::cell::Opaque<T> where T: VMState);
351 unsafe impl $crate::vmstate::VMState for $type {
355 as $crate::vmstate::VMState>::SCALAR_TYPE;
359 as $crate::vmstate::VMState>::BASE;
363 as $crate::vmstate::VMState>::VARRAY_FLAG;
372 unsafe impl VMState for $type { impl
400 ($type:ty where $base:tt: VMState $($where:tt)*) => {
401 unsafe impl<$base> VMState for $type where $base: VMState $($where)* { impl
402 const SCALAR_TYPE: VMStateFieldType = <T as VMState>::SCALAR_TYPE;
403 const BASE: VMStateField = <$base as VMState>::BASE.with_pointer_flag();
408 impl_vmstate_pointer!(*const T where T: VMState);
409 impl_vmstate_pointer!(*mut T where T: VMState);
410 impl_vmstate_pointer!(NonNull<T> where T: VMState);
414 impl_vmstate_pointer!(Box<T> where T: VMState);
415 impl_vmstate_pointer!(Owned<T> where T: VMState + ObjectType);
420 unsafe impl<T: VMState, const N: usize> VMState for [T; N] { impl
421 const SCALAR_TYPE: VMStateFieldType = <T as VMState>::SCALAR_TYPE;
422 const BASE: VMStateField = <T as VMState>::BASE.with_array_flag(N);