Skip to main content

Permit

Struct Permit 

Source
pub struct Permit(/* private fields */);
Expand description

Exclusive native custody lasts for the process once allocator hooks are installed, even if installation fails; copying or dropping Runtime does not release it.

Arena-backed native handles and allocations must remain exclusively owned by their originating worker until release; raw calls and other wrappers must preserve this custody and Cartel’s admitted execution. Foreign initialization and VFS allocations retain their std allocation family and audited native synchronization.

After allocator hook installation, callers must not reconfigure or replace the allocator, page cache, VFS or callbacks, enable URI interpretation, shared caches or native workers, install unaudited extensions, or publish arena-backed storage into global native state.

Implementations§

Source§

impl Permit

Source

pub unsafe fn exclusive() -> Self

§Safety

SQLite must be uninitialized, and no other thread may call SQLite until this permit is consumed by Runtime::install and that call returns; the caller must uphold Permit’s process-lifetime custody contract. The initial default VFS, mutex methods, logging callbacks and auto-extension registry must belong to the audited native implementation without unaudited callbacks or extensions; allocator and page-cache tables replaced without execution may already be installed.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> Convert<T> for T

Source§

fn into(self) -> T

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<'w, 'd, W, P, ID> Sink<'w, 'd, W, ID, Never> for P
where ID: Identity, W: Spec<TerminalFailure = Never> + 'w, P: ?Sized,

Source§

fn fail(&self, _: Id<'d, ID>, cause: Error<'w, W>, _: &mut Token<Identity<'d>>)

Source§

impl<'w, 'd, W, P, ID> Sink<'w, 'd, W, ID, Never> for P
where ID: Identity, W: Spec<OpenFailure = Never> + 'w, P: ?Sized,

Source§

fn fail( &self, _: Completion<'_, 'd, ID>, cause: Error<'w, W>, _: &mut Context<'_, 'd>, )

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.