Skip to main content

StagedEdit

Struct StagedEdit 

Source
pub struct StagedEdit<'a, T>
where T: Clone,
{ /* private fields */ }
Expand description

The common module records and containers. These explicit facade exports keep ordinary callers out of the component crate paths. An isolated candidate for one atomic module edit.

Implementations§

Source§

impl<T> StagedEdit<'_, T>
where T: Clone,

Source

pub const fn value(&self) -> &T

Source

pub const fn value_mut(&mut self) -> &mut T

Source

pub fn diagnostics(&self) -> &[Diagnostic]

Source

pub fn add_diagnostic(&mut self, diagnostic: Diagnostic) -> Result<(), Error>

Add a finding to the candidate under the normal module record checks.

Source

pub fn commit( self, producer: Producer, history: HistoryEntry, ) -> Result<(), Error>

Validate and atomically replace the original module with this candidate. A committed edit keeps source descriptors and prior records, but invalidates retained bytes and source mappings that describe the pre-edit value.

Auto Trait Implementations§

§

impl<'a, T> !UnwindSafe for StagedEdit<'a, T>

§

impl<'a, T> Freeze for StagedEdit<'a, T>
where T: Freeze,

§

impl<'a, T> RefUnwindSafe for StagedEdit<'a, T>
where T: RefUnwindSafe,

§

impl<'a, T> Send for StagedEdit<'a, T>
where T: Send,

§

impl<'a, T> Sync for StagedEdit<'a, T>
where T: Sync,

§

impl<'a, T> Unpin for StagedEdit<'a, T>
where T: Unpin,

§

impl<'a, T> UnsafeUnpin for StagedEdit<'a, T>
where T: UnsafeUnpin,

Blanket Implementations§

§

impl<T> Allocation for T
where T: RefUnwindSafe + Send + Sync,

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
§

impl<T> ByRef<T> for T

§

fn by_ref(&self) -> &T

§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Imply<T> for U
where T: ?Sized, U: ?Sized,

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.

§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

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

Source§

type Error = Infallible

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

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

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.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V