Struct ImplicitClose

Source
pub struct ImplicitClose<LABEL> { /* private fields */ }
Expand description

Critical-edge based Completeness implementation.

Unlike [ExplicitClose], this implementation will implicitly close edges once traversed. This does not require special attention from the type checker writer.

Returns EdgeClosedError when an edge is added to a scope in which the label is already closed (because get_edges(s, l, ...) was called earlier.

When edges are retrieved (e.g. during query resolution) the (src, label) edge is closed.

Trait Implementations§

Source§

impl<LABEL: Hash + Eq + Label, DATA> Completeness<LABEL, DATA> for ImplicitClose<LABEL>

Source§

type NewEdgeResult = Result<(), EdgeClosedError<LABEL>>

Source§

type GetEdgesResult<'rslv> = Vec<Scope> where Self: 'rslv, LABEL: 'rslv, DATA: 'rslv

Source§

fn cmpl_new_scope(&self, _: &InnerScopeGraph<'_, LABEL, DATA>, _: Scope)

Source§

fn cmpl_new_complete_scope( &self, _: &InnerScopeGraph<'_, LABEL, DATA>, _: Scope, )

Should initialize a scope without possibility to extend it with edges
Source§

fn cmpl_new_edge( &self, inner_scope_graph: &InnerScopeGraph<'_, LABEL, DATA>, src: Scope, lbl: LABEL, dst: Scope, ) -> Self::NewEdgeResult

Source§

fn cmpl_get_edges<'rslv>( &self, inner_scope_graph: &InnerScopeGraph<'_, LABEL, DATA>, src: Scope, lbl: LABEL, ) -> Self::GetEdgesResult<'rslv>
where LABEL: 'rslv, DATA: 'rslv,

Source§

impl<LABEL: Hash + Eq + Label, DATA> CriticalEdgeBasedCompleteness<LABEL, DATA> for ImplicitClose<LABEL>

Source§

fn init_scope_with(&self, open_labels: HashSet<LABEL>)

Source§

impl<LABEL> Default for ImplicitClose<LABEL>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<LABEL> !Freeze for ImplicitClose<LABEL>

§

impl<LABEL> !RefUnwindSafe for ImplicitClose<LABEL>

§

impl<LABEL> Send for ImplicitClose<LABEL>
where LABEL: Send,

§

impl<LABEL> !Sync for ImplicitClose<LABEL>

§

impl<LABEL> Unpin for ImplicitClose<LABEL>
where LABEL: Unpin,

§

impl<LABEL> UnwindSafe for ImplicitClose<LABEL>
where LABEL: UnwindSafe,

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