Struct mstd::executor::Terpsichore
source · pub struct Terpsichore {
pub(crate) scheduler: StaticScheduler,
heap_ptr: AtomicPtr<AHeap>,
}
Fields§
§scheduler: StaticScheduler
§heap_ptr: AtomicPtr<AHeap>
Implementations§
source§impl Terpsichore
impl Terpsichore
sourcepub unsafe fn initialize(&'static self, heap_start: *mut u8, heap_len: usize)
pub unsafe fn initialize(&'static self, heap_start: *mut u8, heap_len: usize)
Safety
heap_start
must be a valid pointer to a region of memory of sizeheap_len
.- The region of memory pointed to by
heap_start
must not be mutably aliased.
pub fn run(&'static self)
pub fn get_alloc(&'static self) -> &'static AHeap
pub async fn spawn<F>(&'static self, fut: F) -> JoinHandle<F::Output> ⓘwhere F: Future + Send + 'static, F::Output: Send,
pub fn spawn_allocated<F>( &'static self, task: HeapBox<Task<F>> ) -> JoinHandle<F::Output> ⓘwhere F: Future + Send + 'static, F::Output: Send,
Auto Trait Implementations§
impl !RefUnwindSafe for Terpsichore
impl Send for Terpsichore
impl Sync for Terpsichore
impl Unpin for Terpsichore
impl !UnwindSafe for Terpsichore
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